/**
 * Video Grid Widget styles.
 *
 * Scoped under .rs-video-grid BEM naming.
 *
 * @package RaduSavaVisuals\Widgets
 */

.rs-video-grid {
	box-sizing: border-box;
	color: var(--rs-bone, #ece8e1);
}

.rs-video-grid *,
.rs-video-grid *::before,
.rs-video-grid *::after {
	box-sizing: border-box;
}

/* ==========================================================================
   Featured Hero Layout (Single inline player)
   ========================================================================== */

.rs-video-grid--featured {
	width: 100%;
}

.rs-video-grid__featured-wrap {
	width: 100%;
}

.rs-video-grid__featured-player {
	position: relative;
	aspect-ratio: 16 / 9;
	width: min(100%, calc((100svh - 140px) * 16 / 9));
	margin: 0 auto;
	background: #000;
	overflow: hidden;
}

/* Hello theme button reset */
.rs-video-grid .rs-video-grid__featured-btn {
	all: unset;
	position: absolute;
	inset: 0;
	display: grid;
	place-items: center;
	cursor: pointer;
	border: 0;
	border-radius: 0;
	background: transparent;
	padding: 0;
	color: inherit;
	font: inherit;
}

.rs-video-grid .rs-video-grid__featured-btn:focus-visible {
	outline: 2px solid var(--rs-gold, #e3b26a);
	outline-offset: -2px;
}

.rs-video-grid__featured-img {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 1.2s cubic-bezier(0.2, 0.7, 0.2, 1), opacity 0.4s;
}

.rs-video-grid__featured-btn:hover .rs-video-grid__featured-img {
	transform: scale(1.03);
}

.rs-video-grid__featured-ring {
	position: relative;
	z-index: 2;
	width: clamp(4.5rem, 7vw, 8.4rem);
	aspect-ratio: 1;
	border-radius: 50%;
	border: 1px solid var(--rs-gold, #e3b26a);
	color: var(--rs-gold, #e3b26a);
	background: rgba(8, 8, 7, 0.35);
	display: grid;
	place-items: center;
	transition: background 0.3s, color 0.3s, transform 0.3s;
}

.rs-video-grid__featured-ring svg {
	width: 28%;
	margin-left: 6%;
}

.rs-video-grid__featured-btn:hover .rs-video-grid__featured-ring,
.rs-video-grid__featured-btn:focus-visible .rs-video-grid__featured-ring {
	background: var(--rs-gold, #e3b26a);
	color: var(--rs-film, #0b0b0a);
	transform: scale(1.06);
}

.rs-video-grid__featured-iframe {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: 0;
}

.rs-video-grid__featured-cap {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	gap: 16px;
	flex-wrap: wrap;
	margin: 14px 0 0;
	font-family: var(--rs-font-mono, 'IBM Plex Mono', ui-monospace, monospace);
	font-size: clamp(0.688rem, 0.76vw, 0.912rem);
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--rs-bone-2, #a7a198);
}

.rs-video-grid__featured-title {
	color: var(--rs-bone, #ece8e1);
	font-weight: 500;
}

.rs-video-grid__featured-meta {
	color: var(--rs-bone-2, #a7a198);
}

/* ==========================================================================
   Video Grid Layout (Cards)
   ========================================================================== */

.rs-video-grid__grid {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(var(--rs-vg-cols, 2), minmax(0, 1fr));
	column-gap: clamp(1rem, 2vw, 2.4rem);
	row-gap: clamp(2.25rem, 4vw, 4.4rem);
}

.rs-video-grid__card {
	list-style: none;
	margin: 0;
	padding: 0;
}

/* Hello theme button reset for cards */
.rs-video-grid .rs-video-grid__btn {
	all: unset;
	display: block;
	width: 100%;
	cursor: pointer;
	border: 0;
	border-radius: 0;
	background: transparent;
	padding: 0;
	text-align: left;
	color: inherit;
	font: inherit;
}

.rs-video-grid .rs-video-grid__btn:focus-visible {
	outline: 2px solid var(--rs-gold, #e3b26a);
	outline-offset: 4px;
}

.rs-video-grid__thumbnail {
	position: relative;
	display: block;
	aspect-ratio: 16 / 9;
	overflow: hidden;
	background: #1a1917;
}

.rs-video-grid__img {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 1.2s cubic-bezier(0.2, 0.7, 0.2, 1), filter 0.4s;
}

.rs-video-grid__btn:hover .rs-video-grid__img {
	transform: scale(1.04);
}

.rs-video-grid__ring {
	position: absolute;
	left: clamp(0.75rem, 1.2vw, 1.375rem);
	bottom: clamp(0.75rem, 1.2vw, 1.375rem);
	width: clamp(2.75rem, 3.4vw, 4rem);
	aspect-ratio: 1;
	border-radius: 50%;
	border: 1px solid rgba(236, 232, 225, 0.7);
	color: var(--rs-bone, #ece8e1);
	background: rgba(8, 8, 7, 0.35);
	display: grid;
	place-items: center;
	transition: background 0.3s, color 0.3s, border-color 0.3s, transform 0.3s;
}

.rs-video-grid__ring svg {
	width: 30%;
	margin-left: 6%;
}

.rs-video-grid__btn:hover .rs-video-grid__ring,
.rs-video-grid__btn:focus-visible .rs-video-grid__ring {
	background: var(--rs-gold, #e3b26a);
	border-color: var(--rs-gold, #e3b26a);
	color: var(--rs-film, #0b0b0a);
	transform: scale(1.08);
}

.rs-video-grid__title {
	display: block;
	margin: clamp(0.875rem, 1.2vw, 1.375rem) 0 6px;
	line-height: 0.95;
	color: var(--rs-bone, #ece8e1);
	transition: color 0.3s;
}

.rs-video-grid__grid--archivo .rs-video-grid__title {
	font-family: var(--rs-font-film, Archivo, Manrope, system-ui, sans-serif);
	font-weight: 800;
	font-stretch: 78%;
	text-transform: uppercase;
	letter-spacing: -0.01em;
	font-size: clamp(1.5rem, 2vw, 2.4rem);
}

.rs-video-grid__grid--serif .rs-video-grid__title {
	font-family: var(--rs-font-display, 'Cormorant Garamond', Georgia, serif);
	font-weight: 300;
	font-stretch: normal;
	text-transform: none;
	letter-spacing: -0.01em;
	font-size: clamp(1.375rem, 1.6vw, 1.92rem);
	line-height: 1.05;
}

.rs-video-grid__btn:hover .rs-video-grid__title {
	color: var(--rs-gold, #e3b26a);
}

.rs-video-grid__meta {
	display: block;
	margin: 0;
	font-family: var(--rs-font-mono, 'IBM Plex Mono', ui-monospace, monospace);
	font-size: clamp(0.688rem, 0.72vw, 0.875rem);
	letter-spacing: 0.12em;
	text-transform: uppercase;
	line-height: 1.6;
	color: var(--rs-bone-2, #a7a198);
}

.rs-video-grid__award {
	display: block;
	margin-top: 10px;
	font-family: var(--rs-font-mono, 'IBM Plex Mono', ui-monospace, monospace);
	font-size: clamp(0.688rem, 0.72vw, 0.875rem);
	letter-spacing: 0.12em;
	text-transform: uppercase;
	line-height: 1.5;
	color: var(--rs-gold, #e3b26a);
}

.rs-video-grid .rs-video-grid__ext {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin-top: 10px;
	color: var(--rs-bone, #ece8e1);
	font-family: var(--rs-font-mono, 'IBM Plex Mono', ui-monospace, monospace);
	font-size: clamp(0.688rem, 0.72vw, 0.875rem);
	letter-spacing: 0.12em;
	text-transform: uppercase;
	text-decoration: none;
	border-bottom: 1px solid rgba(236, 232, 225, 0.35);
	transition: border-color 0.2s, color 0.2s;
}

.rs-video-grid .rs-video-grid__ext:hover {
	border-color: var(--rs-gold, #e3b26a);
	color: var(--rs-gold, #e3b26a);
}

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */

@media (max-width: 1024px) {
	.rs-video-grid__grid {
		--rs-vg-cols: 2;
	}
}

@media (max-width: 767px) {
	.rs-video-grid__grid {
		--rs-vg-cols: 1;
	}
}

/* ==========================================================================
   Reduced Motion
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
	.rs-video-grid__featured-img,
	.rs-video-grid__img,
	.rs-video-grid__featured-ring,
	.rs-video-grid__ring {
		transition: none !important;
	}
}
