/* ═══════════════════════════════════════════════════════════
   JD BRANDS — Single brand page (same look as a glossary term)
═══════════════════════════════════════════════════════════ */

.jdb-brand-page {
	width: 100%;
}

/* ── Headline ─────────────────────────────────────────── */

.jdb-brand-headline {
	text-align: center;
	margin-bottom: 48px;
}

/* Title — mirrors .category-page-title */
.jdb-brand-page-title {
	font-family: var(--jd-font-heading) !important;
	font-size: 40px !important;
	font-weight: 700 !important;
	line-height: 1.15 !important;
	color: #222 !important;
	margin: 0 0 12px !important;
}

.jdb-brand-page-back {
	font-family: var(--jd-font-body);
	font-size: 16px;
	font-weight: 600;
	margin: 0;
	letter-spacing: 0.02em;
}

.jdb-brand-page-back a {
	color: var(--jd-color-accent);
	text-decoration: none;
}

.jdb-brand-page-back a:hover {
	text-decoration: underline;
}

/* Logo frame — same box for every brand; the logo is scaled to fit inside
   (object-fit: contain), so wide wordmarks and square marks look balanced */
.jdb-brand-logo {
	--jdb-logo-w: 320px;
	--jdb-logo-h: 160px;
	width: var(--jdb-logo-w);
	max-width: 100%;
	height: var(--jdb-logo-h);
	margin: 32px auto 0;
	padding: 20px;
	box-sizing: border-box;
	display: flex;
	align-items: center;
	justify-content: center;
}

.jdb-brand-logo-img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: contain;
	object-position: center;
}

/* ── Body: facts + description + image ────────────────── */

.jdb-brand-body {
	margin-bottom: 56px;
}

.jdb-brand-facts {
	margin: 0 0 32px;
	padding: 0;
	border-top: 1px solid #eff1f1;
}

.jdb-brand-fact {
	display: grid;
	grid-template-columns: 220px 1fr;
	gap: 16px;
	padding: 14px 0;
	border-bottom: 1px solid #eff1f1;
	font-family: var(--jd-font-body);
	font-size: 16px;
	line-height: 1.6;
}

.jdb-brand-fact dt {
	color: #888;
	font-size: 14px;
	padding-top: 2px;
}

.jdb-brand-fact dd {
	margin: 0;
	color: #222;
	font-weight: 500;
}

.jdb-collections {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.jdb-collections li {
	margin: 0;
	padding: 4px 12px;
	border: 1px solid #eff1f1;
	border-radius: 999px;
	font-size: 14px;
	font-weight: 500;
	line-height: 1.5;
}

.jdb-brand-description {
	font-family: var(--jd-font-body);
	font-size: 16px;
	line-height: 1.75;
	color: #333;
}

.jdb-brand-description p {
	margin: 0 0 1em;
}

.jdb-brand-description p:last-child {
	margin-bottom: 0;
}

/* ── Linked posts ─────────────────────────────────────── */

.jdb-brand-related {
	background: #F9FAFB;
	margin-left:  calc(-50vw + 50%);
	margin-right: calc(-50vw + 50%);
	padding: 36px calc(50vw - 50%) 56px;
}

.jdb-brand-related-heading {
	font-family: var(--jd-font-heading) !important;
	font-size: 28px !important;
	font-weight: 700 !important;
	color: #222 !important;
	margin: 0 0 32px !important;
}

.jdb-brand-related-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 32px;
}

.jdb-related-card .card-image.wp-block-post-featured-image {
	border-radius: 4px;
	overflow: hidden;
	display: block;
	margin-bottom: 14px;
}

.jdb-related-card .card-image.wp-block-post-featured-image a {
	display: block;
	overflow: hidden;
	border-radius: 4px;
}

.jdb-related-card .card-image.wp-block-post-featured-image img {
	display: block;
	width: 100%;
	height: 200px;
	object-fit: cover;
	border-radius: 4px;
	transition: transform 0.35s ease;
}

.jdb-related-card:hover .card-image.wp-block-post-featured-image img {
	transform: scale(1.05);
}

/* ── Responsive ─────────────────────────────────────────── */

@media (max-width: 900px) {
	.jdb-brand-related-grid {
		grid-template-columns: 1fr 1fr;
	}
}

@media (max-width: 640px) {
	.jdb-brand-page-title {
		font-size: 28px !important;
	}

	.jdb-brand-headline {
		margin-bottom: 32px;
	}

	.jdb-brand-logo {
		--jdb-logo-w: 240px;
		--jdb-logo-h: 120px;
		margin-top: 24px;
		padding: 16px;
	}

	.jdb-brand-fact {
		grid-template-columns: 1fr;
		gap: 4px;
	}

	.jdb-brand-related-grid {
		grid-template-columns: 1fr;
	}
}

/* ── Social links ─────────────────────────────────────── */

.jdb-social {
	display: flex;
	flex-wrap: wrap;
	gap: 6px 20px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.jdb-social li {
	margin: 0;
}

.jdb-social a {
	color: var(--jd-color-accent);
	text-decoration: none;
}

.jdb-social a:hover {
	text-decoration: underline;
}
