/* Homebuyer Group: blog v2 ("Guides"). Loads after home-v2.css and reuses its tokens,
   header, footer, buttons, CTA and offer form. Only blog-specific pieces live here. */

.stack-sm { display: flex; flex-direction: column; gap: 16px; }
.wrap--article { max-width: 1200px; }
.hbg-v2 .site-nav a.is-current { color: var(--green); font-weight: 600; }

/* ---------- Breadcrumbs ---------- */
.crumbs ol { display: flex; flex-wrap: wrap; gap: 4px 0; font-size: 14px; color: var(--muted); }
.crumbs li { display: flex; align-items: center; }
.crumbs li + li::before { content: "/"; margin: 0 10px; color: var(--border-strong); }
.hbg-v2 .crumbs a { color: var(--muted); text-decoration: none; display: inline-flex; align-items: center; min-height: 32px; }
.hbg-v2 .crumbs a:hover { color: var(--green); text-decoration: underline; }
.crumbs [aria-current] { color: var(--ink); font-weight: 500; }

/* ---------- Index head ---------- */
.blog-head { background: var(--mint); border-bottom: 1px solid var(--border); }
.blog-head .wrap { padding-top: 40px; padding-bottom: 40px; }
.hbg-v2 .blog-head__title { font-size: clamp(2.2rem, 4.4vw, 3.6rem); line-height: 1.05; letter-spacing: -0.02em; }
.blog-head__intro { font-size: 19px; color: var(--body); max-width: 680px; }

.topics ul { display: flex; flex-wrap: wrap; gap: 10px; padding-top: 8px; }
.hbg-v2 .topics a {
	display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px;
	border: 1.5px solid var(--card-border); border-radius: 999px; background: var(--white);
	color: var(--ink); font-size: 15px; font-weight: 600; text-decoration: none;
	transition: border-color .15s, background-color .15s;
}
.hbg-v2 .topics a:hover { border-color: var(--green); color: var(--ink); }
.hbg-v2 .topics a[aria-current] { background: var(--green); border-color: var(--green); color: var(--white); }

/* ---------- Post cards ---------- */
.section--blog { padding: 56px 0 72px; }
.post-grid { display: grid; gap: 24px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); }
.post-grid--three { grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); }
.post-card {
	position: relative; display: flex; flex-direction: column; overflow: hidden;
	background: var(--white); border: 1px solid var(--card-border); border-radius: var(--radius-lg);
	transition: border-color .15s, box-shadow .15s;
}
.post-card:hover { border-color: var(--green); box-shadow: 0 8px 24px rgba(22, 23, 25, .08); }
.post-card:focus-within { border-color: var(--green); }
.post-card__img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; background: var(--surface); }
.post-card__body { flex: 1; display: flex; flex-direction: column; gap: 10px; padding: 24px; border-top: 4px solid var(--green); }
.post-card__img + .post-card__body { border-top: 0; }
.post-card__topic { font-size: 13px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--green); }
.hbg-v2 .post-card__title { font-size: 22px; font-weight: 700; line-height: 1.2; }
.hbg-v2 .post-card__title a { color: var(--ink); text-decoration: none; }
/* The whole card is clickable through the title link; there's still only one link per card. */
.post-card__title a::after { content: ""; position: absolute; inset: 0; border-radius: var(--radius-lg); }
.hbg-v2 .post-card__title a:focus-visible { box-shadow: none; }
.hbg-v2 .post-card__title a:focus-visible::after { box-shadow: var(--focus); }
.post-card__excerpt { color: var(--body); font-size: 16px; }
.post-card__meta { margin-top: auto; padding-top: 6px; font-size: 14px; color: var(--muted); }

@media (min-width: 760px) {
	.post-card--featured { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); }
	.post-card--featured .post-card__img { height: 100%; aspect-ratio: auto; min-height: 320px; }
	.post-card--featured .post-card__body { padding: 40px; justify-content: center; border-top: 0; border-left: 6px solid var(--green); }
	.post-card--featured .post-card__img + .post-card__body { border-left: 0; }
	.hbg-v2 .post-card--featured .post-card__title { font-size: clamp(1.7rem, 2.6vw, 2.2rem); line-height: 1.12; }
	.post-card--featured .post-card__excerpt { font-size: 18px; }
	.post-card--featured .post-card__meta { margin-top: 8px; }
	/* Without an image, the featured card is one wide text card. */
	.post-card--featured:not(:has(.post-card__img)) { display: flex; }
	.post-card--featured:not(:has(.post-card__img)) .post-card__body { max-width: none; }
}

.blog-empty { font-size: 18px; color: var(--body); }

/* ---------- Pagination ---------- */
.pager ul { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.pager .page-numbers {
	display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; padding: 0 14px;
	border: 1.5px solid var(--card-border); border-radius: 10px; color: var(--ink); font-weight: 600; text-decoration: none;
}
.hbg-v2 .pager a.page-numbers:hover { border-color: var(--green); color: var(--green); }
.pager .page-numbers.current { background: var(--ink); border-color: var(--ink); color: var(--white); }
.pager .page-numbers.dots { border: 0; min-width: 0; padding: 0 4px; }

/* ---------- Article head ---------- */
.article-head { background: var(--mint); border-bottom: 1px solid var(--border); }
.article-head .wrap { padding-top: 36px; padding-bottom: 40px; }
.article-head .wrap > * { max-width: 820px; }
.hbg-v2 a.article-head__topic { text-decoration: none; align-self: flex-start; display: inline-flex; align-items: center; min-height: 44px; margin: -11px 0; }
.hbg-v2 a.article-head__topic:hover { text-decoration: underline; }
.hbg-v2 .article-head__title { font-size: clamp(2.1rem, 4.4vw, 3.4rem); line-height: 1.06; letter-spacing: -0.02em; }
.article-head__lead { font-size: 20px; line-height: 1.5; color: var(--body); }
.article-head__meta { font-size: 15px; color: var(--muted); }
.article-head__meta span { white-space: nowrap; }
.article-head__meta span + span::before { content: "·"; margin: 0 8px; }
.article-head__meta strong { color: var(--ink); font-weight: 600; }

/* ---------- Article layout ---------- */
.article-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; padding-top: 40px; padding-bottom: 56px; }
.article-main { min-width: 0; max-width: 760px; }
.article-side { display: flex; flex-direction: column; gap: 20px; }
@media (min-width: 1000px) {
	.article-layout { grid-template-columns: minmax(0, 760px) 320px; justify-content: space-between; gap: 56px; padding-top: 56px; }
	.article-side { grid-column: 2; grid-row: 1; align-self: start; position: sticky; top: 104px; }
	.article-main { grid-column: 1; grid-row: 1; }
}
.article-figure { margin: 0 0 32px; }
.article-figure img { width: 100%; border-radius: var(--radius-lg); }
.article-figure figcaption { margin-top: 8px; font-size: 14px; color: var(--muted); }

/* Contents list */
.toc { border: 1px solid var(--card-border); border-radius: var(--radius-lg); padding: 20px 22px; background: var(--white); }
.toc__title { font-family: var(--font-head); font-size: 18px; font-weight: 700; margin-bottom: 8px; }
.toc ol { counter-reset: toc; display: flex; flex-direction: column; }
.toc li { counter-increment: toc; display: grid; grid-template-columns: 24px 1fr; align-items: center; }
.toc li::before { content: counter(toc) "."; font-size: 14px; font-weight: 600; color: var(--muted); }
.hbg-v2 .toc a { display: flex; align-items: center; min-height: 44px; padding: 4px 0; font-size: 15px; line-height: 1.4; color: var(--ink); text-decoration: none; }
.hbg-v2 .toc a:hover { color: var(--green); text-decoration: underline; }

/* Sidebar CTA: desktop only; phones have the sticky bottom bar and the CTA after the article. */
.side-cta { display: none; }
@media (min-width: 1000px) {
	.side-cta { display: flex; flex-direction: column; gap: 12px; padding: 24px; border-radius: var(--radius-lg); background: var(--deep-green); color: var(--white); }
	.side-cta__title { font-family: var(--font-head); font-size: 22px; font-weight: 800; line-height: 1.15; }
	.side-cta p { color: #D3E3D8; font-size: 15px; }
	.side-cta .side-cta__title { color: var(--white); }
	.side-cta .side-cta__small { font-size: 14px; }
	.hbg-v2 .side-cta a:not(.btn) { color: var(--white); font-weight: 600; }
	.hbg-v2 .side-cta :focus-visible { box-shadow: 0 0 0 3px var(--green-light); }
}

/* ---------- Article body (Classic Editor HTML) ---------- */
.prose { font-size: 18px; line-height: 1.7; color: #2F323A; }
.hbg-v2 .prose > * + * { margin-top: 1.1em; }
.hbg-v2 .prose h2 { font-size: clamp(1.6rem, 2.6vw, 2rem); line-height: 1.15; margin-top: 1.8em; color: var(--ink); scroll-margin-top: 104px; }
.hbg-v2 .prose h3 { font-size: 21px; margin-top: 1.5em; color: var(--ink); }
.hbg-v2 .prose h4 { font-family: var(--font-body); font-size: 18px; font-weight: 700; margin: 1.4em 0 0; color: var(--ink); }
.hbg-v2 .prose > :first-child { margin-top: 0; }
.hbg-v2 .prose h2 + *, .hbg-v2 .prose h3 + *, .hbg-v2 .prose h4 + * { margin-top: .6em; }
.hbg-v2 .prose ul, .hbg-v2 .prose ol { padding-left: 1.4em; margin-bottom: 0; }
.hbg-v2 .prose ul { list-style: disc; }
.hbg-v2 .prose ol { list-style: decimal; }
.hbg-v2 .prose li + li { margin-top: .4em; }
.prose li::marker { color: var(--green); font-weight: 700; }
.prose strong { color: var(--ink); }
.hbg-v2 .prose a { color: var(--green); font-weight: 500; text-decoration: underline; }
.hbg-v2 .prose a:hover { color: var(--green-dark); }
.prose blockquote { margin-left: 0; margin-right: 0; padding: 4px 0 4px 20px; border-left: 4px solid var(--green); font-size: 20px; color: var(--ink); }
.prose hr { border: 0; border-top: 1px solid var(--border); margin: 2em 0; }
.prose img { border-radius: var(--radius); }
.prose figure, .prose .wp-caption { margin-left: 0; margin-right: 0; max-width: 100%; }
.prose figcaption, .prose .wp-caption-text { margin-top: 8px; font-size: 14px; color: var(--muted); }
.prose .alignleft { float: left; margin: .3em 1.5em 1em 0; max-width: 50%; }
.prose .alignright { float: right; margin: .3em 0 1em 1.5em; max-width: 50%; }
.prose .aligncenter { margin-left: auto; margin-right: auto; }
.prose::after { content: ""; display: table; clear: both; }
.prose table { width: 100%; border-collapse: collapse; font-size: 16px; display: block; overflow-x: auto; }
.prose th, .prose td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--border); vertical-align: top; }
.prose th { font-weight: 700; color: var(--ink); background: var(--surface); }
/* A "Key point" box: in the Classic Editor, add <p class="callout">…</p> or <div class="callout">…</div>. */
.prose .callout { background: var(--green-tint); border-left: 4px solid var(--green); border-radius: var(--radius); padding: 18px 20px; color: var(--ink); }
.prose .callout strong:first-child { display: block; margin-bottom: 4px; font-family: var(--font-head); font-size: 18px; }
/* "Last checked" line at the end of a guide. */
.prose .guide-checked { margin-top: 2em; padding-top: 16px; border-top: 1px solid var(--border); font-size: 15px; color: var(--muted); }
@media (max-width: 720px) {
	.prose { font-size: 17px; }
	.prose .alignleft, .prose .alignright { float: none; margin: 0; max-width: 100%; }
	.article-head__lead { font-size: 18px; }
}

/* ---------- After-article CTA ---------- */
.article-cta { padding: 0 0 72px; }
.article-cta__box {
	max-width: 760px; display: flex; flex-direction: column; gap: 16px; align-items: flex-start;
	padding: 40px; border-radius: 20px; background: var(--deep-green); color: var(--white);
}
.hbg-v2 .article-cta__box h2 { font-size: clamp(1.7rem, 3vw, 2.3rem); line-height: 1.1; }
.article-cta__box > p { color: #D3E3D8; font-size: 17px; }
.article-cta__box .postcode-bar { max-width: none; }
.hbg-v2 .article-cta__box :focus-visible { box-shadow: 0 0 0 3px var(--green-light); }
.hbg-v2 .article-cta__box .final-cta__small a { color: var(--white); font-weight: 600; }
@media (max-width: 520px) { .article-cta__box { padding: 28px 20px; } }

/* ---------- More guides ---------- */
.related__head { display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; align-items: baseline; }
.related__head a { font-weight: 600; display: inline-flex; align-items: center; min-height: 44px; }
.hbg-v2 .related .post-card__title { font-size: 20px; }

@media (prefers-reduced-motion: reduce) {
	.post-card, .topics a { transition: none; }
}

/* ---------- Investor Hub (templates/page-investors-v2.php) ---------- */
.inv-hero { background: var(--near-black); color: var(--white); }
.inv-hero__inner { display: flex; flex-wrap: wrap; gap: 48px; align-items: center; padding-top: 48px; padding-bottom: 72px; }
.inv-hero__copy { flex: 999 1 520px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.hbg-investors .inv-hero .crumbs ol { color: #A9ADB8; }
.hbg-investors .inv-hero .crumbs a { color: #A9ADB8; }
.hbg-investors .inv-hero .crumbs a:hover { color: var(--white); }
.hbg-investors .inv-hero .crumbs li + li::before { color: #5A5E69; }
.hbg-investors .inv-hero .crumbs [aria-current] { color: var(--white); }
.inv-hero .eyebrow { color: var(--green-light); }
.hbg-v2 .inv-hero__title { font-size: clamp(2.4rem, 5vw, 3.9rem); line-height: 1.04; }
.inv-hero__lead { font-size: 19px; line-height: 1.6; color: #C9CCD6; max-width: 620px; }
.inv-hero__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; }
.inv-hero__note { font-size: 15px; color: #A9ADB8; }
.inv-ticks { display: flex; flex-direction: column; gap: 10px; font-size: 16px; color: #E3E5EA; }
.inv-ticks li { display: flex; gap: 10px; align-items: flex-start; }
.inv-ticks li::before { content: ""; flex: 0 0 20px; height: 20px; margin-top: 2px; background: no-repeat center / 20px url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235CC384' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m5 12 5 5 9-10'/%3E%3C/svg%3E"); }
.inv-hero__card { flex: 1 1 320px; min-width: 0; max-width: 420px; background: #1B2A21; border: 1.5px solid var(--green); border-radius: 20px; padding: 28px; display: flex; flex-direction: column; gap: 20px; }
.hbg-v2 .inv-hero__card h2 { font-size: 24px; line-height: 1.2; color: var(--white); }
.inv-start { display: flex; flex-direction: column; gap: 12px; }
.hbg-v2 .inv-start label { color: #D3E3D8; }
.hbg-v2 .inv-start input { border-color: transparent; }
.inv-next { display: flex; flex-direction: column; gap: 10px; counter-reset: inv-next 1; }
.inv-next li { counter-increment: inv-next; display: flex; align-items: center; gap: 12px; font-size: 15px; color: #D3E3D8; }
.inv-next li::before { content: counter(inv-next); flex: 0 0 26px; height: 26px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: rgba(92, 195, 132, .16); color: var(--green-light); font-family: var(--font-head); font-weight: 800; font-size: 14px; }
.inv-hero__card-foot { font-size: 14px; color: #A9C4B2; }
.hbg-v2 .inv-hero :focus-visible { box-shadow: 0 0 0 3px var(--green-light); }
.hbg-v2 .inv-start input:focus-visible { border-color: var(--green-light); box-shadow: 0 0 0 3px rgba(92, 195, 132, .45); }

.inv-deals .card > svg, .inv-why__item > svg { color: var(--green); }
.hbg-v2 .inv-deals { grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); }
.inv-why { grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); }
.inv-why__item { display: flex; flex-direction: column; gap: 10px; background: var(--white); border-radius: var(--radius-lg); padding: 24px; }
.inv-why__item p { color: var(--body); }
.inv-steps { grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); }

.inv-terms { display: flex; flex-wrap: wrap; gap: 32px 64px; }
.inv-terms__head { flex: 1 1 280px; display: flex; flex-direction: column; gap: 12px; }
.inv-terms__head p { color: #C9CCD6; font-size: 18px; }
.inv-terms__list { flex: 2 1 440px; min-width: 0; display: flex; flex-direction: column; gap: 0; }
.inv-terms__list li { padding: 18px 0; border-bottom: 1px solid #2C2F36; color: #C9CCD6; }
.inv-terms__list li:first-child { padding-top: 0; }
.inv-terms__list strong { color: var(--white); }
.inv-terms__small { flex: 1 1 100%; font-size: 14px; color: #A9ADB8; }

.offer__done-link { display: flex; flex-direction: column; align-items: center; gap: 16px; }
@media (max-width: 600px) {
	.inv-hero__inner { padding-top: 24px; padding-bottom: 48px; gap: 32px; }
	.inv-hero__actions .btn { width: 100%; }
	.inv-hero__card { padding: 22px 18px; }
}
