/* Journal: listing (home.html), topic archives (archive.html) and articles (single.html). */

/* ---------- Breadcrumb ---------- */
.tz-crumbs { margin-top: 0 !important; margin-bottom: var(--tz-crumbs-gap) !important; }
.tz-crumbs ol { display: flex; flex-wrap: wrap; gap: 4px 0; margin: 0; padding: 0; list-style: none; font-size: 11px; line-height: 16px; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; color: var(--tz-muted); }
.tz-crumbs li + li::before { content: "/"; margin: 0 8px; color: var(--tz-line-strong); }
.tz-crumbs a { color: var(--tz-muted); text-decoration: none; }
.tz-crumbs a:hover { color: var(--tz-ink); }
.tz-crumbs [aria-current] { color: var(--tz-ink); }

/* ---------- Listing header ---------- */
.tz-journal-page { padding-top: var(--wp--preset--spacing--50); padding-bottom: var(--wp--preset--spacing--90); }
.tz-jhead { margin-bottom: var(--wp--preset--spacing--60) !important; }
.tz-jhead > * { margin: 0 !important; max-width: 760px; }
.tz-jhead .tz-eyebrow { margin-bottom: 12px !important; }
.tz-jhead__title { font-size: var(--wp--preset--font-size--display-1); line-height: 1.12; }
.tz-jhead__intro { margin-top: 14px !important; font-size: 17px; line-height: 28px; color: var(--tz-muted); }
.tz-jhead__intro p { margin: 0; }

/* ---------- Topics ---------- */
.tz-topics { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 8px; margin-top: 0 !important; margin-bottom: var(--wp--preset--spacing--70) !important; padding-bottom: var(--wp--preset--spacing--60); border-bottom: 1px solid var(--tz-line); }
.tz-topics__list { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
.tz-topic {
	display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 14px; border: 1px solid var(--tz-line); border-radius: 999px;
	background: #fff; color: var(--tz-ink); font-size: 14px; line-height: 1; text-decoration: none; white-space: nowrap; transition: border-color .15s ease, background-color .15s ease, color .15s ease;
}
.tz-topic:hover { border-color: var(--tz-ink); }
.tz-topic[aria-current="page"] { background: var(--tz-ink); border-color: var(--tz-ink); color: var(--tz-surface); }
.tz-topic__count { font-size: 12px; color: var(--tz-muted); font-variant-numeric: tabular-nums; }
.tz-topic[aria-current="page"] .tz-topic__count { color: rgba(247,245,241,.7); }
.tz-topics__more { display: contents; }
.tz-topics__more > summary {
	display: inline-flex; align-items: center; gap: 8px; min-height: 36px; padding: 0 6px; list-style: none; cursor: pointer;
	color: var(--tz-forest); font-size: 14px; text-decoration: underline; text-underline-offset: 3px;
}
.tz-topics__more > summary::-webkit-details-marker { display: none; }
.tz-topics__more > summary svg { transition: transform .2s ease; }
.tz-topics__more[open] > summary svg { transform: rotate(180deg); }
.tz-topics__more > summary:hover { color: var(--tz-ink); }
.tz-topics__list--more { flex-basis: 100%; animation: tz-topics-in .2s ease both; }
@keyframes tz-topics-in { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }

/* ---------- Cards ---------- */
.tz-jlist { display: grid !important; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 56px 24px; margin: 0; padding: 0; list-style: none; }
.tz-jlist > li { position: relative; margin: 0; }
.tz-jcard { display: flex; flex-direction: column; gap: 0; margin: 0 !important; height: 100%; }
.tz-jcard > * { margin: 0 !important; }
.tz-post-media { margin-top: 0 !important; margin-bottom: 18px !important; }
/* Cards built in PHP (related stories) have no block wrapper round the image, so space it here too. */
.tz-jlist .tz-jcard > .tz-media__link, .tz-jlist .tz-jcard > .tz-media { margin-bottom: 18px !important; }
.tz-media { position: relative; overflow: hidden; background: var(--tz-stone); }
.tz-media__img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.tz-media__link { display: block; color: inherit; }
.tz-jlist > li:hover .tz-media__img { transform: scale(1.03); }
.tz-media__placeholder { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; background: radial-gradient(circle at 50% 40%, #efebe4 0, var(--tz-stone) 70%); color: var(--tz-sand); }
.tz-media__placeholder svg { width: 22%; max-width: 96px; height: auto; opacity: .8; }

.tz-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 0; margin-top: 0 !important; margin-bottom: 10px !important; font-size: 11px; line-height: 16px; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; color: var(--tz-muted); }
.tz-meta__topic { position: relative; z-index: 2; color: var(--tz-ink); text-decoration: none; }
.tz-meta__topic:hover { text-decoration: underline; text-underline-offset: 3px; }
.tz-meta__sep { display: inline-block; width: 3px; height: 3px; margin: 0 10px; border-radius: 50%; background: var(--tz-line-strong); }
.tz-jcard__title { margin: 0 !important; font-size: 24px; line-height: 30px; }
.tz-jcard__title a { color: var(--tz-ink); text-decoration: none; }
.tz-jcard__title a::after { content: ""; position: absolute; inset: 0; z-index: 1; } /* whole card clickable */
.tz-jlist > li:hover .tz-jcard__title a { text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 1px; }
.tz-jcard__excerpt { display: none; }
.tz-jcard__excerpt p { margin: 0; }
.tz-jcard__excerpt .wp-block-post-excerpt__more-text { display: none; }

/* First story on the first page: large, image beside the text */
body:not(.paged) .tz-journal-query .tz-jlist > li:first-child { grid-column: 1 / -1; padding-bottom: 56px; border-bottom: 1px solid var(--tz-line); }
body:not(.paged) .tz-journal-query .tz-jlist > li:first-child .tz-jcard { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 48px; align-items: center; }
body:not(.paged) .tz-journal-query .tz-jlist > li:first-child .tz-post-media { margin-bottom: 0 !important; }
body:not(.paged) .tz-journal-query .tz-jlist > li:first-child .tz-media { aspect-ratio: 3 / 2 !important; }
body:not(.paged) .tz-journal-query .tz-jlist > li:first-child .tz-jcard__title { font-size: var(--wp--preset--font-size--display-1); line-height: 1.12; }
body:not(.paged) .tz-journal-query .tz-jlist > li:first-child .tz-jcard__excerpt { display: block; margin-top: 16px !important; font-size: 16px; line-height: 26px; color: var(--tz-muted); }
.tz-journal-query .tz-pagination { margin-top: var(--wp--preset--spacing--80); }

/* Related stories */
.tz-related-stories { padding: var(--wp--preset--spacing--90) var(--wp--style--root--padding-left, 48px); border-top: 1px solid var(--tz-line); }
.tz-related-stories__inner { max-width: 1320px; margin: 0 auto; }
.tz-related-stories .tz-heading > div > * { margin: 0; }
.tz-related-stories .tz-eyebrow { margin-bottom: 16px; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
	.tz-jlist { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.tz-jlist--related > li:nth-child(3) { display: none; }
}
@media (max-width: 782px) {
	body:not(.paged) .tz-journal-query .tz-jlist > li:first-child .tz-jcard { grid-template-columns: 1fr; gap: 20px; }
	.tz-prose { font-size: 17px; }
	.tz-prose .alignleft, .tz-prose .alignright { float: none; margin: 0 0 1em; max-width: 100%; }
}
@media (max-width: 640px) {
	.tz-jlist { grid-template-columns: 1fr; gap: 40px; }
	.tz-jlist--related > li:nth-child(3) { display: block; }
	.tz-topic { min-height: 34px; padding: 0 12px; font-size: 13px; }
	.tz-jhead__title, body:not(.paged) .tz-journal-query .tz-jlist > li:first-child .tz-jcard__title { font-size: 34px; }
	.tz-prose h2 { font-size: 26px; }
}
@media (prefers-reduced-motion: reduce) {
	.tz-media__img, .tz-topics__more > summary svg, .tz-topics__list--more { transition: none; animation: none; }
}
