/* ==========================================================================
   Blog widget — ported from pestcontrolgroupusa_core_old
   (components.css .blog__*, layout.css .blog__nav/__viewport/__track).
   Classes are namespaced pcgu-blog(__*) to avoid collisions with other
   plugins/themes; rendered output otherwise matches the original exactly.
   Shares .section-head*, .js-carousel-* (drag-carousel.js) with Services
   (same generic carousel) — see shared.css/Assets_Manager, not duplicated.

   The nav buttons are <button> elements, so the theme's reset.css
   "[type=button],[type=submit],button {...}" rule (transparent background,
   var(--primary) border, var(--radius-sm) corners, padding, and a colored
   hover background) fights bare ".pcgu-blog__nav-btn" selectors at the
   same (0,1,0)/(0,1,1) specificity — same gotcha as Header/Process/FAQ.
   Fixed by prefixing with the widget wrapper class and explicitly
   overriding every property the reset also touches. ---- */

.pcgu-blog {
	position: relative;
	overflow: hidden;
	background-color: color-mix(in oklab, var(--muted) 40%, transparent);
}

.pcgu-blog__blob {
	position: absolute;
	z-index: 0;
	border-radius: 9999px;
	filter: blur(60px);
	pointer-events: none;
}
.pcgu-blog__blob--a {
	left: -5rem;
	top: 4rem;
	height: 16rem;
	width: 16rem;
	background-color: color-mix(in oklab, var(--secondary) 16%, transparent);
}
.pcgu-blog__blob--b {
	right: -6rem;
	bottom: 2rem;
	height: 18rem;
	width: 18rem;
	background-color: color-mix(in oklab, var(--accent) 20%, transparent);
}

.pcgu-blog .container {
	position: relative;
	z-index: 1;
}

.pcgu-blog__nav {
	position: relative;
	z-index: 1;
	margin-top: 2rem;
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 0.75rem;
}

.pcgu-blog .pcgu-blog__nav-btn {
	display: grid;
	place-items: center;
	height: 2.75rem;
	width: 2.75rem;
	border-radius: 9999px;
	border: 1px solid var(--border);
	background-color: var(--card);
	color: var(--foreground);
	padding: 0;
	white-space: normal;
	transition: background-color 200ms, color 200ms, border-color 200ms, opacity 200ms;
}
.pcgu-blog .pcgu-blog__nav-btn:hover:not(:disabled) {
	background-color: var(--card);
	border-color: var(--secondary);
	color: var(--secondary);
}
.pcgu-blog .pcgu-blog__nav-btn:disabled {
	opacity: 0.4;
	cursor: default;
}
.pcgu-blog .pcgu-blog__nav-btn--next {
	background-image: var(--gradient-call);
	border-color: transparent;
	color: #fff;
}
.pcgu-blog .pcgu-blog__nav-btn--next:hover:not(:disabled) {
	background-color: transparent;
	color: #fff;
	filter: brightness(1.1);
}

.pcgu-blog__viewport {
	position: relative;
	z-index: 1;
	margin-top: 1rem;
	/* Padding gives the hover-lifted card's shadow/border room to breathe —
	   overflow-x:auto implicitly clips overflow-y too, so without this the
	   card's top and left edges get cut off by the scroll container. */
	padding: 0.75rem 0.25rem 1.25rem;
	margin-inline: -0.25rem;
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	scrollbar-width: none;
}
.pcgu-blog__viewport::-webkit-scrollbar {
	display: none;
}
.pcgu-blog__viewport.is-dragging {
	cursor: grabbing;
	scroll-snap-type: none;
	user-select: none;
}
.pcgu-blog__track {
	display: grid;
	grid-auto-flow: column;
	grid-auto-columns: 88%;
	gap: 1.5rem;
	padding-inline: 0.25rem;
}

.pcgu-blog__card {
	position: relative;
	z-index: 1;
	scroll-snap-align: start;
	display: flex;
	flex-direction: column;
	border-radius: var(--radius-2xl);
	border: 1px solid oklch(0.85 0.02 250);
	background-color: var(--card);
	padding: 1.25rem;
	box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
	transition: transform 250ms, box-shadow 250ms, border-color 250ms;
}
.pcgu-blog__card:hover {
	transform: translateY(-4px);
	border-color: oklch(0.78 0.03 250);
	box-shadow: 0 16px 32px -16px rgba(15, 23, 42, 0.18);
}
.pcgu-blog__card-media {
	position: relative;
	aspect-ratio: 4 / 3;
	overflow: hidden;
	border-radius: var(--radius-xl);
}
.pcgu-blog .pcgu-blog__card-img {
	/* Elementor's `.elementor img { height: auto; max-width: 100% }` reset
	   is (0,1,1), beating a bare `.pcgu-blog__card-img` (0,1,0) — same
	   collision documented for the Footer logo. Prefixed with the widget
	   wrapper class to reach (0,2,0), so images actually fill the fixed
	   4:3 media box instead of rendering at their own natural height. */
	height: 100%;
	width: 100%;
	max-width: none;
	object-fit: cover;
	transition: transform 400ms;
}
.pcgu-blog__card:hover .pcgu-blog__card-img {
	transform: scale(1.05);
}
.pcgu-blog__card-tag {
	position: absolute;
	left: 0.75rem;
	top: 0.75rem;
	border-radius: 9999px;
	background-color: color-mix(in oklab, var(--card) 92%, transparent);
	backdrop-filter: blur(4px);
	padding: 0.25rem 0.75rem;
	font-size: 0.6875rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	color: var(--secondary);
}
.pcgu-blog__card-title {
	margin-top: 1.25rem;
	font-size: 1.0625rem;
	font-weight: 700;
	line-height: 1.35;
	color: var(--foreground);
}
.pcgu-blog__card-excerpt {
	/* margin-bottom is a guaranteed minimum gap before the footer even when
	   this card is the tallest in its row (where the footer's own
	   margin-top:auto would otherwise have no free space left to fill). */
	margin: 0.5rem 0 1rem 0;
	font-size: 0.875rem;
	line-height: 1.625;
	color: var(--muted-foreground);
}
.pcgu-blog__card-footer {
	/* auto (not a fixed value) pins the footer to the bottom of the
	   .pcgu-blog__card flex column regardless of how many lines the
	   excerpt above it wraps to, so "Read more" lines up across cards
	   with different excerpt lengths (same fix as Services' cards). */
	margin-top: auto;
	padding-top: 1rem;
	border-top: 1px solid var(--border);
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
}
.pcgu-blog__card-meta {
	display: inline-flex;
	align-items: center;
	gap: 0.375rem;
	font-size: 0.75rem;
	color: var(--muted-foreground);
	white-space: nowrap;
}
.pcgu-blog__card-meta svg {
	height: 0.875rem;
	width: 0.875rem;
}
.pcgu-blog__card-link {
	display: inline-flex;
	align-items: center;
	gap: 0.375rem;
	font-size: 0.8125rem;
	font-weight: 600;
	color: var(--secondary);
	transition: color 200ms;
	white-space: nowrap;
}
.pcgu-blog__card-link:hover {
	color: var(--primary);
}
.pcgu-blog__card-link svg {
	height: 0.875rem;
	width: 0.875rem;
}

/* ---- Responsive — exact original breakpoints (sm:640 / md:768 / lg:1024) ---- */

@media (min-width: 640px) {
	.pcgu-blog__track { grid-auto-columns: 60%; }
}

@media (min-width: 768px) {
	.pcgu-blog__track { grid-auto-columns: 42%; }
}

@media (min-width: 1024px) {
	.pcgu-blog__track { grid-auto-columns: 31%; }
}
