/**
 * CarsNow Child Theme — Authentic Pinterest Masonry Gallery CSS
 */

/* =============================================================
   1. GLOBAL & CONTAINER
   ============================================================= */

.vv-family-page {
	font-family: 'Manrope', -apple-system, BlinkMacSystemFont, sans-serif;
	color: #111;
	background: #fafafa;
	overflow-x: hidden;
}

.vv-family-container {
	max-width: 1440px;
	margin: 0 auto;
	padding: 0 24px;
}

/* =============================================================
   2. HERO SECTION
   ============================================================= */

.vv-family-hero {
	position: relative;
	padding: 70px 0 50px;
	background: #0d0d0f;
	color: #fff;
	text-align: center;
}

.vv-family-hero__bg {
	position: absolute;
	inset: 0;
	background: radial-gradient(circle at 50% 40%, rgba(232, 0, 28, 0.15) 0%, rgba(13, 13, 15, 0.98) 75%);
}

.vv-family-hero__container {
	position: relative;
	z-index: 2;
	max-width: 800px;
	margin: 0 auto;
	padding: 0 20px;
}

.vv-family-hero__eyebrow {
	display: inline-block;
	font-size: 0.75rem;
	font-weight: 700;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: #e8001c;
	margin-bottom: 12px;
}

.vv-family-hero__title {
	font-size: clamp(2.2rem, 4.5vw, 3.4rem);
	font-weight: 800;
	line-height: 1.15;
	color: #fff;
	letter-spacing: -0.02em;
	margin-bottom: 14px;
}

.vv-family-hero__highlight {
	color: #e8001c;
}

.vv-family-hero__subtitle {
	font-size: clamp(0.95rem, 1.5vw, 1.1rem);
	line-height: 1.55;
	color: rgba(255, 255, 255, 0.7);
	margin: 0 auto;
}

/* =============================================================
   3. AUTHENTIC PINTEREST MASONRY GALLERY
   ============================================================= */

.vv-family-gallery-sec {
	padding: 40px 0 80px;
}

.vv-family-masonry {
	column-count: 4;
	column-gap: 20px;
	width: 100%;
}

.vv-family-card {
	break-inside: avoid;
	display: inline-block;
	width: 100%;
	margin-bottom: 20px;
	border-radius: 16px;
	overflow: hidden;
	background: #0f1013;
	position: relative;
	cursor: pointer;
	content-visibility: auto;
	contain-intrinsic-size: 320px 420px;
	contain: layout style paint;
	transform: translateZ(0);
	-webkit-backface-visibility: hidden;
	backface-visibility: hidden;
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
	transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.3s ease;
}

.vv-family-card:hover {
	transform: translateY(-6px) translateZ(0);
	box-shadow: 0 16px 36px rgba(0, 0, 0, 0.18);
}

.vv-family-card__inner {
	width: 100%;
	height: auto;
	position: relative;
	display: block;
	transform: translateZ(0);
}

.vv-family-card__media {
	width: 100%;
	height: auto;
	position: relative;
	overflow: hidden;
	display: block;
	transform: translateZ(0);
}

.vv-family-card__img {
	width: 100%;
	height: auto;
	display: block;
	object-fit: cover;
	transform: translateZ(0);
	-webkit-backface-visibility: hidden;
	backface-visibility: hidden;
	transition: transform 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.vv-family-card:hover .vv-family-card__img {
	transform: scale(1.04) translateZ(0);
}

/* Pinterest Floating Action Button on Hover */
.vv-family-card__pin-btn {
	position: absolute;
	top: 14px;
	right: 14px;
	z-index: 4;
	display: flex;
	align-items: center;
	gap: 6px;
	padding: 7px 14px;
	border-radius: 24px;
	background: #e8001c;
	color: #fff;
	font-size: 0.78rem;
	font-weight: 700;
	letter-spacing: 0.02em;
	opacity: 0;
	transform: translateY(-8px) scale(0.9);
	transition: opacity 0.25s ease, transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
	pointer-events: none;
	box-shadow: 0 4px 14px rgba(232, 0, 28, 0.4);
}

.vv-family-card:hover .vv-family-card__pin-btn {
	opacity: 1;
	transform: translateY(0) scale(1);
}

/* Reel / Video Icon */
.vv-family-card__reel-icon {
	position: absolute;
	top: 14px;
	left: 14px;
	z-index: 3;
	display: flex;
	align-items: center;
	gap: 5px;
	padding: 5px 10px;
	border-radius: 16px;
	background: rgba(0, 0, 0, 0.75);
	color: #fff;
	font-size: 0.7rem;
	font-weight: 600;
}

/* Bottom Caption Overlay */
.vv-family-card__caption {
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	z-index: 2;
	background: linear-gradient(to top, rgba(0, 0, 0, 0.88) 0%, rgba(0, 0, 0, 0.5) 55%, transparent 100%);
	padding: 36px 16px 14px;
	color: #fff;
	display: flex;
	flex-direction: column;
	gap: 5px;
	transform: translateZ(0);
	transition: opacity 0.25s ease;
}

.vv-family-card:hover .vv-family-card__caption {
	opacity: 1;
}

.vv-family-card__name {
	font-size: 0.92rem;
	font-weight: 700;
	color: #fff;
	margin: 0;
	line-height: 1.25;
}

.vv-family-card__tag {
	display: inline-block;
	align-self: flex-start;
	font-size: 0.72rem;
	font-weight: 600;
	color: #fff;
	background: rgba(255, 255, 255, 0.22);
	padding: 2px 8px;
	border-radius: 4px;
	letter-spacing: 0.02em;
}

/* =============================================================
   4. LIGHTBOX MODAL (Pure Media Viewer)
   ============================================================= */

.vv-family-modal {
	position: fixed;
	inset: 0;
	z-index: 999999;
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.3s ease, visibility 0.3s ease;
}

.vv-family-modal.is-open {
	opacity: 1;
	visibility: visible;
}

.vv-family-modal__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.92);
	backdrop-filter: blur(10px);
}

.vv-family-modal__dialog {
	position: relative;
	z-index: 2;
	width: 90%;
	max-width: 820px;
	max-height: 88vh;
	background: #000;
	border-radius: 18px;
	overflow: hidden;
	box-shadow: 0 24px 80px rgba(0, 0, 0, 0.7);
	display: flex;
	flex-direction: column;
	transform: scale(0.95);
	transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.vv-family-modal.is-open .vv-family-modal__dialog {
	transform: scale(1);
}

.vv-family-modal__close {
	position: absolute;
	top: 14px;
	right: 14px;
	z-index: 10;
	width: 38px;
	height: 38px;
	border-radius: 50%;
	border: none;
	background: rgba(0, 0, 0, 0.6);
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	transition: background 0.2s ease;
}

.vv-family-modal__close:hover {
	background: #e8001c;
}

.vv-family-modal__media-container {
	flex: 1;
	width: 100%;
	height: 100%;
	max-height: 78vh;
	display: flex;
	align-items: center;
	justify-content: center;
	background: #000;
	overflow: hidden;
}

.vv-family-modal__media-container img {
	max-width: 100%;
	max-height: 78vh;
	object-fit: contain;
}

.vv-family-modal__media-container iframe {
	width: 100%;
	height: 100%;
	min-height: 480px;
	border: none;
}

.vv-family-modal__footer-caption {
	padding: 14px 20px;
	background: #111;
	color: #fff;
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 0.9rem;
	border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.vv-family-modal__name {
	font-weight: 700;
}

.vv-family-modal__dot {
	color: #666;
}

.vv-family-modal__vehicle {
	color: #e8001c;
	font-weight: 600;
}

/* =============================================================
   5. RESPONSIVE PINTEREST BREAKPOINTS
   ============================================================= */

@media (max-width: 1200px) {
	.vv-family-masonry {
		column-count: 3;
		column-gap: 16px;
	}
	.vv-family-card {
		margin-bottom: 16px;
	}
}

@media (max-width: 768px) {
	.vv-family-masonry {
		column-count: 2;
		column-gap: 12px;
	}

	.vv-family-card {
		margin-bottom: 12px;
		border-radius: 12px;
	}

	.vv-family-card__pin-btn {
		display: none;
	}

	.vv-family-hero {
		padding: 50px 0 35px;
	}
}

@media (max-width: 480px) {
	.vv-family-masonry {
		column-count: 2;
		column-gap: 10px;
	}
	.vv-family-card {
		margin-bottom: 10px;
		border-radius: 10px;
	}
}
