/* ==========================================================================
   Video modal (gallery playback)
   ========================================================================== */

.video-card__thumb {
	border: 0;
	padding: 0;
	background: none;
	cursor: pointer;
	font: inherit;
	text-align: left;
	width: 100%;
}

.video-modal {
	position: fixed;
	inset: 0;
	z-index: 2000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 1rem;
}

.video-modal[hidden] {
	display: none;
}

.video-modal__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(10, 10, 10, 0.85);
}

.video-modal__dialog {
	position: relative;
	z-index: 1;
	width: min(100%, 960px);
	background: #000;
	border-radius: 4px;
	overflow: hidden;
	box-shadow: 0 24px 80px rgba(0, 0, 0, 0.5);
}

.video-modal__dialog--short {
	width: min(100%, 400px);
}

.video-modal__embed {
	position: relative;
	aspect-ratio: 16 / 9;
}

.video-modal__dialog--short .video-modal__embed {
	aspect-ratio: 9 / 16;
	max-height: 85vh;
}

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

.video-modal__close {
	position: absolute;
	top: 0.5rem;
	right: 0.5rem;
	z-index: 2;
	width: 40px;
	height: 40px;
	padding: 0;
	font-size: 1.5rem;
	line-height: 1;
	color: #fff;
	background: rgba(0, 0, 0, 0.6);
	border: 2px solid rgba(255, 255, 255, 0.5);
	border-radius: 4px;
	cursor: pointer;
}

.video-modal__title {
	margin: 0;
	padding: 1rem;
	font-size: 1rem;
	font-weight: 700;
	color: #fff;
	background: #111;
}

body.video-modal-open {
	overflow: hidden;
}

.videos-page-shell .video-section:first-of-type {
	margin-top: 0;
}
