/* Widget Scoped Structural Defaults */
.cg-wrapper {
	width: 100%;
}
.cg-filters {
	display: flex;
	flex-wrap: wrap;
}
.cg-filter-group {
	display: flex;
	flex-direction: column;
}
.cg-filter-buttons {
	display: flex;
}
.cg-filter-btn {
	padding: 0 20px;
	background: transparent;
	cursor: pointer;
	border-radius: 0; /* Fallback square */
	border: 1px solid transparent;
	transition: all 0.2s ease;
}

/* Select wrapper for custom chevron */
.cg-filter-select-wrapper {
	position: relative;
	display: inline-block;
}
.cg-filter-select {
	appearance: none;
	-webkit-appearance: none;
	-moz-appearance: none;
	padding: 0 32px 0 16px;
	border-radius: 0; /* Fallback square */
	border: 1px solid transparent;
	cursor: pointer;
}
.cg-filter-select-arrow {
	content: "";
	position: absolute;
	right: 14px;
	top: 50%;
	transform: translateY(-50%);
	width: 0; 
	height: 0; 
	border-left: 5px solid transparent;
	border-right: 5px solid transparent;
	border-top: 5px solid #999;
	pointer-events: none;
}

.cg-grid {
	display: grid;
}
.cg-card {
	display: flex;
	flex-direction: column;
	position: relative; /* For stretched link */
}

/* CRITICAL FIX: Ensure hidden cards are truly hidden despite Elementor flex/grid overrides */
.cg-card[hidden] {
	display: none !important;
}

/* Clickable card styles (stretched link) */
.cg-stretched-link::after {
	content: "";
	position: absolute;
	top: 0;
	right: 0;
	bottom: 0;
	left: 0;
	z-index: 1;
	pointer-events: auto;
}
/* Allow other links inside the card to be clickable on top of the stretched link, if any (usually not needed since the whole card is one link target) */
.cg-card-clickable .cg-card-link,
.cg-card-clickable .cg-card-tags a {
	position: relative;
	z-index: 2;
}

/* Ensure the fallback 'View details' link looks clickable but doesn't create a secondary full overlay if the title already did */
.cg-stretched-link-fallback {
	position: relative;
	z-index: 2;
}


.cg-card-image img {
	display: block;
}
.cg-card-content {
	flex-grow: 1;
	display: flex;
	flex-direction: column;
}
.cg-card-title {
	margin: 0;
	padding: 0;
}
.cg-card-title a {
	text-decoration: none;
}
.cg-card-excerpt p {
	margin: 0;
}
.cg-card-tags {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
}
.cg-tag {
	display: inline-block;
}
.cg-card-link {
	display: inline-block;
}
