.bf-vg {
	display: grid;
	grid-template-columns: repeat(var(--bf-vg-columns, 3), 1fr);
	gap: var(--bf-vg-gap, 10px);
}

.bf-vg-item {
	position: relative;
	overflow: hidden;
	cursor: pointer;
	background: #000;
}

.bf-vg-thumb {
	position: relative;
	width: 100%;
	overflow: hidden;
}

.bf-vg-thumb img,
.bf-vg-thumb video {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.bf-vg-overlay {
	position: absolute;
	inset: 0;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	background-color: rgba(0, 0, 0, 0.4);
	opacity: 0;
	transition: opacity 0.3s ease;
}

.bf-vg-item:hover .bf-vg-overlay {
	opacity: 1;
}

.bf-vg-play {
	width: 50px;
	height: 50px;
	color: #fff;
	filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.bf-vg-title {
	margin-top: 8px;
	color: #fff;
	font-size: 14px;
	font-weight: 500;
	text-align: center;
	text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
	padding: 0 10px;
}

/* Lightbox */
.bf-vg-lightbox {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(0, 0, 0, 0.9);
	opacity: 0;
	transition: opacity 0.3s ease;
}

.bf-vg-lightbox.bf-vg-active {
	opacity: 1;
}

.bf-vg-lightbox video {
	max-width: 90vw;
	max-height: 90vh;
	outline: none;
}

/* Inline video */
.bf-vg-inline-video {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.bf-vg-lightbox-close {
	position: absolute;
	top: 20px;
	right: 20px;
	width: 36px;
	height: 36px;
	border: none;
	background: rgba(255, 255, 255, 0.15);
	border-radius: 50%;
	color: #fff;
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.2s;
}

.bf-vg-lightbox-close:hover {
	background: rgba(255, 255, 255, 0.3);
}
