/* =====================================================================
   Blogs index (24–25 Nov 2026) — pages/blogs.php: /blogs, /blogs/page/N/ and
   the topics /blogs-category/…/ (one page for all).
   Page 1: topic chips (2+ topics) · topic heading · 1 large wide card · 3 regular cards · "More posts"
   · 8 list rows · numbered stepper. Page 2+: chips · 12 rows · stepper.
   Phones: the large card stacks, the 3 cards become list rows, the chips
   scroll sideways, the stepper keeps numbers but drops the words.
   List rows = the shared component (assets/css/list-row.css); cards use the
   shared hover (.awwrt-hover-card), so hover, press and focus match the site.
   ===================================================================== */

.blogs-archive-page {
	/* page base (moved here from the old inline <style> in pages/blogs.php, removed 24 Nov 2026) */
	width: 100%;
	background: #15171d;
	color: #ffffff;

	--bi-text-strong: #e2e5ec;
	--bi-text: #cfd4dd;
	--bi-text-muted: #aab4c6;
	--bi-text-dim: #8b94a7;
	--bi-line: #353a45;
	--bi-cover: #292d36;          /* the site's placeholder grey */
	--bi-glass: rgba(255, 255, 255, 0.06);
	--bi-glass-hover: rgba(255, 255, 255, 0.11);
	--bi-light: rgba(241, 242, 246, 0.92);
}

/* "Page 2 of 3" under the heading (template-parts/page-heading.php 'note') */
.awwrt-page-heading-note { margin: 12px 0 0; font-size: 13px; line-height: 1.4; color: #8b94a7; }

/* ---- topic chips ---------------------------------------------------- */
.awwrt-topic-chips { width: 100%; max-width: 1080px; margin: 0 auto 72px; padding: 0 20px; }
.awwrt-topic-chips ul {
	display: flex; flex-wrap: wrap; justify-content: center; gap: 8px;
	list-style: none; margin: 0; padding: 0;
}
.awwrt-topic-chips a {
	display: inline-flex; align-items: center; height: 36px; padding: 0 16px;
	border-radius: 999px; background: var(--bi-glass); color: var(--bi-text);
	font-size: 14px; font-weight: 500; line-height: 1; text-decoration: none; white-space: nowrap;
	box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
	transition: background-color 0.2s ease, color 0.2s ease;
}
.awwrt-topic-chips a:hover { background: var(--bi-glass-hover); color: #fff; }
.awwrt-topic-chips a[aria-current="page"] { background: var(--bi-light); color: #15171d; box-shadow: none; }
.awwrt-topic-chips a:focus-visible { outline: 2px solid #75b8ff; outline-offset: 2px; }

/* ---- the index column ----------------------------------------------- */
.awwrt-blog-index { width: 100%; padding: 0 20px 120px; }
.awwrt-blog-index-inner { max-width: 1040px; margin: 0 auto; }
/* no tabs: the heading keeps the same 72px it has under them (40px on phones, from the search) */
@media (min-width: 768px) { .awwrt-blog-index.has-no-tabs { padding-top: 32px; } }

.awwrt-card-meta { display: block; margin: 0; font-size: 13px; line-height: 1.4; color: var(--bi-text-dim); font-variant-numeric: tabular-nums; }

/* ---- 1. large wide card --------------------------------------------- */
.awwrt-large-card {
	display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 56px;   /* picture left, text right (24 Nov 2026) */ align-items: center;
	color: inherit; text-decoration: none;
}
.awwrt-large-card-title {
	margin: 0 0 20px; font-size: 30px; line-height: 1.25; font-weight: 700; color: var(--bi-text-strong);
	text-wrap: balance; overflow-wrap: anywhere;
}
.awwrt-large-card-excerpt {
	margin: 0 0 24px; font-size: 16px; line-height: 1.6; color: var(--bi-text-muted);
	display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.awwrt-large-card-image {
	order: -1;
	aspect-ratio: 16 / 10; border-radius: 7px; overflow: hidden; background: var(--bi-cover);
}
.awwrt-large-card-image img { display: block; width: 100%; height: 100%; object-fit: cover; }

/* ---- 2. three regular cards ----------------------------------------- */
.awwrt-card-grid {
	display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px;
	list-style: none; margin: 96px 0 0; padding: 0;
}
.awwrt-card-grid > li { margin: 0; padding: 0; min-width: 0; }
.awwrt-card-grid > li::before, .awwrt-card-grid > li::marker { content: none; }
.awwrt-post-card { display: flex; flex-direction: column; gap: 12px; color: inherit; text-decoration: none; height: 100%; }
.awwrt-post-card-image { display: block; aspect-ratio: 16 / 10; border-radius: 7px; overflow: hidden; background: var(--bi-cover); }
.awwrt-post-card-image img { display: block; width: 100%; height: 100%; object-fit: cover; }
/* title = the small list row title (list-row.css .awwrt-help-title); keep the two matched */
.awwrt-post-card-title {
	display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
	margin-top: 12px; font-size: 22px; line-height: 1.27; letter-spacing: -.016em; font-weight: 700; color: var(--bi-text-strong); overflow-wrap: anywhere;
}
/* support text: same colour as the list rows, 1 line (25 Nov 2026) */
.awwrt-post-card-excerpt {
	display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden;
	font-size: 15px; line-height: 1.5; color: var(--bi-text-muted); overflow-wrap: anywhere;
}
.awwrt-post-card .awwrt-card-meta { margin-top: 4px; }
/* the same 3 posts as list rows: phones only */
.awwrt-cards-as-rows.awwrt-help-list { display: none; }

/* ---- 3. "More posts" + list rows ------------------------------------ */
.awwrt-more-heading { margin: 112px 0 20px; font-size: 20px; line-height: 1.3; font-weight: 700; color: #fff; }
.awwrt-blog-index .awwrt-index-list { margin: 0; }
.awwrt-blog-index > .awwrt-blog-index-inner > .awwrt-index-list:first-child { margin-top: 0; }
.awwrt-blog-empty { text-align: center; color: var(--bi-text-muted); padding: 48px 0; }

/* ---- stepper -------------------------------------------------------- */
.awwrt-pager {
	display: flex; align-items: center; justify-content: center; gap: 12px;
	margin: 80px 0 0; padding-top: 40px; border-top: 1px solid var(--bi-line);
}
.awwrt-pager-numbers { display: flex; align-items: center; gap: 6px; list-style: none; margin: 0; padding: 0; }
.awwrt-pager-numbers li { margin: 0; padding: 0; }
.awwrt-pager-numbers li::before, .awwrt-pager-numbers li::marker { content: none; }
.awwrt-pager-numbers :is(a, span),
.awwrt-pager-step {
	display: inline-flex; align-items: center; justify-content: center; gap: 6px;
	min-width: 40px; height: 40px; padding: 0 12px; border-radius: 999px;
	font-size: 14px; font-weight: 500; line-height: 1; text-decoration: none;
	color: var(--bi-text); background: var(--bi-glass);
	box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
	transition: background-color 0.2s ease, color 0.2s ease;
	font-variant-numeric: tabular-nums;
}
.awwrt-pager-step { padding: 0 16px; }
.awwrt-pager-numbers a:hover, a.awwrt-pager-step:hover { background: var(--bi-glass-hover); color: #fff; }
.awwrt-pager-numbers .current { background: var(--bi-light); color: #15171d; box-shadow: none; }
.awwrt-pager-numbers .dots { background: none; box-shadow: none; min-width: 24px; padding: 0; color: var(--bi-text-dim); }
.awwrt-pager-step.is-disabled { opacity: 0.35; cursor: default; }
.awwrt-pager-step svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.awwrt-pager :is(a):focus-visible { outline: 2px solid #75b8ff; outline-offset: 2px; }

/* ---- tablet --------------------------------------------------------- */
@media (max-width: 1023px) {
	.awwrt-large-card { gap: 40px; }
	.awwrt-large-card-title { font-size: 24px; }
	.awwrt-card-grid { gap: 28px; margin-top: 80px; }
}

/* ---- phones --------------------------------------------------------- */
@media (max-width: 767px) {
	/* chips scroll sideways, starting at the page edge */
	.awwrt-topic-chips { padding: 0; margin-bottom: 40px; }
	.awwrt-topic-chips ul {
		flex-wrap: nowrap; justify-content: flex-start; overflow-x: auto; padding: 5px 20px; margin: -5px 0;   /* room for the focus ring */
		scrollbar-width: none; overscroll-behavior-x: contain;
	}
	.awwrt-topic-chips ul::-webkit-scrollbar { display: none; }

	.awwrt-blog-index { padding-bottom: 96px; }
	/* large card: picture on top, text below */
	.awwrt-large-card { grid-template-columns: 1fr; gap: 20px; }
	.awwrt-large-card-title { font-size: 22px; margin-bottom: 12px; }
	.awwrt-large-card-excerpt { font-size: 15px; margin-bottom: 16px; }

	/* the 3 cards become list rows, continuing straight into the rest */
	.awwrt-card-grid { display: none; }
	.awwrt-cards-as-rows.awwrt-help-list { display: flex; }
	.awwrt-blog-index .awwrt-cards-as-rows { margin-top: 48px; border-top: 1px solid var(--bi-line); }
	.awwrt-blog-index .awwrt-cards-as-rows > li.is-first .awwrt-help-row { --pt: 28px; }
	.awwrt-blog-index .awwrt-cards-as-rows > li.is-last .awwrt-help-row { --pb: 28px; }
	.awwrt-blog-index .awwrt-cards-as-rows + .awwrt-more-heading { display: none; }
	.awwrt-blog-index .awwrt-cards-as-rows ~ .awwrt-index-list > li.is-first { border-top: 1px solid var(--bi-line); }
	.awwrt-blog-index .awwrt-cards-as-rows ~ .awwrt-index-list > li.is-first .awwrt-help-row { --pt: 28px; }

	/* stepper: numbers stay, the words go; big round buttons for thumbs */
	.awwrt-pager { gap: 8px; margin-top: 48px; padding-top: 24px; }
	.awwrt-pager-numbers { gap: 4px; }
	.awwrt-pager-step { width: 40px; padding: 0; }
	.awwrt-pager-step > span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
	.awwrt-pager-numbers :is(a, span) { min-width: 40px; padding: 0 8px; }
	.awwrt-pager-numbers .dots { min-width: 16px; padding: 0; }
}
/* small phones: with many pages, keep only the current page and its neighbours
   (‹ 4 5 6 ›) so the stepper never runs off the screen */
@media (max-width: 479px) {
	.awwrt-pager-numbers li.is-end,
	.awwrt-pager-numbers li.is-dots { display: none; }
}

/* ---- small list: narrower than the cards, centred (24 Nov 2026) ------ */
/* cards 1040px, list rows 680px. Phones: full width. */
@media (min-width: 768px) {
	.awwrt-blog-index :is(.awwrt-more-heading, .awwrt-index-list, .awwrt-pager, .awwrt-topic-heading.is-narrow) { max-width: 680px; margin-left: auto; margin-right: auto; }
}

/* ---- roomier list rows on /blogs and topics (24 Nov 2026) ------------- */
/* Guides and related guides keep the shared row spacing (list-row.css). */
:is(.awwrt-index-list, .awwrt-cards-as-rows) .awwrt-help-text { gap: 10px; }
:is(.awwrt-index-list, .awwrt-cards-as-rows) .awwrt-help-excerpt { line-height: 1.5; }
:is(.awwrt-index-list, .awwrt-cards-as-rows) .awwrt-help-meta { margin-top: 6px; }
:is(.awwrt-index-list, .awwrt-cards-as-rows).awwrt-help-list > li:not(.is-first) .awwrt-help-row { --pt: 36px; }
:is(.awwrt-index-list, .awwrt-cards-as-rows).awwrt-help-list > li:not(.is-last) .awwrt-help-row { --pb: 36px; }
@media (max-width: 767px) {
	:is(.awwrt-index-list, .awwrt-cards-as-rows).awwrt-help-list > li:not(.is-first) .awwrt-help-row { --pt: 28px; }
	:is(.awwrt-index-list, .awwrt-cards-as-rows).awwrt-help-list > li:not(.is-last) .awwrt-help-row { --pb: 28px; }
}

/* ---- topic heading under the chips + the swap (24 Nov 2026) ----------- */
/* a quiet label, so the post title leads (option E, 25 Nov 2026); heading = "More posts" */
.awwrt-topic-heading { margin: 0 0 28px; }
.awwrt-topic-heading :is(h1, h2) { margin: 0; font-size: 20px; line-height: 1.3; font-weight: 700; color: #fff; overflow-wrap: anywhere; }
.awwrt-topic-heading p { margin: 4px 0 0; font-size: 15px; line-height: 1.5; color: var(--bi-text-muted); }
@media (max-width: 767px) {
	.awwrt-topic-heading { margin-bottom: 24px; }
}
.awwrt-blog-index { transition: opacity 0.16s ease; }
.awwrt-blog-index.is-swapping { opacity: 0; }
@media (prefers-reduced-motion: reduce) { .awwrt-blog-index { transition: none; } }
