/* Footer covers + the full-screen story player. Covers look like video thumbnails; the player is a calm, glassy stage with product cards. */

/* ================================================================ covers in the footer grid */
.bl-ig2__shot--video {
	position: relative;
	display: block;
	width: 100%;
	padding: 0;
	border: 0;
	background: var(--bl-brand-hover);
	color: #fff;
	cursor: pointer;
	isolation: isolate;
}

.bl-ig2__shot {
	position: relative;
	border-radius: 0;
}

.bl-ig2__shot--video .bl-ig2__img {
	transition: transform 0.9s cubic-bezier(0.2, 0.7, 0.2, 1), filter 0.5s ease;
}

.bl-ig2__shot--video:hover .bl-ig2__img,
.bl-ig2__shot--video:focus-visible .bl-ig2__img {
	transform: scale(1.06);
	filter: saturate(1.08);
}

.bl-ig2__shot--video::after {
	content: '';
	position: absolute;
	inset: 0;
	z-index: 1;
	background: linear-gradient(180deg, rgba(30, 24, 12, 0) 55%, rgba(30, 24, 12, 0.6));
	opacity: 0;
	transition: opacity 0.4s ease;
}

.bl-ig2__shot--video:hover::after,
.bl-ig2__shot--video:focus-visible::after {
	opacity: 1;
}

.bl-ig2__play {
	position: absolute;
	top: 12px;
	right: 12px;
	z-index: 3;
	display: grid;
	place-items: center;
	width: 34px;
	height: 34px;
	padding-left: 2px;
	border: 1px solid rgba(255, 255, 255, 0.55);
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.18);
	-webkit-backdrop-filter: blur(8px);
	backdrop-filter: blur(8px);
	color: #fff;
	transition: transform 0.35s cubic-bezier(0.2, 1.4, 0.3, 1), background-color 0.3s ease, color 0.3s ease;
}

.bl-ig2__shot--video:hover .bl-ig2__play,
.bl-ig2__shot--video:focus-visible .bl-ig2__play {
	background: #fff;
	color: var(--bl-brand);
	transform: scale(1.12);
}

.bl-ig2__cap {
	position: absolute;
	right: 14px;
	bottom: 14px;
	left: 14px;
	z-index: 3;
	display: grid;
	gap: 4px;
	text-align: left;
	transform: translateY(8px);
	opacity: 0;
	transition: transform 0.4s ease, opacity 0.4s ease;
}

.bl-ig2__shot--video:hover .bl-ig2__cap,
.bl-ig2__shot--video:focus-visible .bl-ig2__cap {
	transform: none;
	opacity: 1;
}

.bl-ig2__count {
	font: 400 10.5px/1 var(--bl-sans);
	letter-spacing: 0.08em;
	text-transform: uppercase;
	opacity: 0.85;
}

.bl-ig2__name {
	font: 400 17px/1.2 var(--bl-serif);
}

@media (hover: none) {
	.bl-ig2__cap {
		opacity: 1;
		transform: none;
	}
	.bl-ig2__shot--video::after {
		opacity: 1;
	}
}

/* ================================================================ player */
.bl-vp {
	position: fixed;
	inset: 0;
	z-index: 2200;
	display: grid;
	place-items: center;
	color: #fff;
}

.bl-vp[hidden] {
	display: none;
}

.bl-vp__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(24, 19, 9, 0.72);
	-webkit-backdrop-filter: blur(18px) saturate(1.1);
	backdrop-filter: blur(18px) saturate(1.1);
	animation: bl-vp-fade 0.35s ease both;
}

/* the cover of the playing item glows softly behind everything */
.bl-vp__ambient {
	position: absolute;
	inset: -10%;
	background: center / cover no-repeat;
	filter: blur(70px) saturate(1.3);
	opacity: 0.55;
	transition: background-image 0.6s ease;
	pointer-events: none;
}

@keyframes bl-vp-fade {
	from {
		opacity: 0;
	}
}

.bl-vp__layout {
	position: relative;
	z-index: 2;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 36px;
	width: 100%;
	max-height: 100%;
	padding: 24px;
	pointer-events: none;
}

.bl-vp__layout > * {
	pointer-events: auto;
}

.bl-vp__stage {
	position: relative;
	flex: none;
	width: min(calc((100vh - 64px) * 9 / 16), 440px);
	aspect-ratio: 9 / 16;
	overflow: hidden;
	border-radius: 28px;
	background: #1c160a;
	box-shadow: 0 50px 90px -30px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.bl-vp__media,
.bl-vp__still,
.bl-vp__video {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
}

.bl-vp__still,
.bl-vp__video {
	object-fit: cover;
	-webkit-user-drag: none;
}

.bl-vp__video {
	opacity: 0;
	transition: opacity 0.3s ease;
}

.bl-vp.is-video .bl-vp__video {
	opacity: 1;
}

.bl-vp.is-story .bl-vp__still {
	animation: bl-vp-kb 7s ease-out both;
	animation-play-state: var(--bl-vp-run, running);
}

@keyframes bl-vp-kb {
	from {
		transform: scale(1.02);
	}
	to {
		transform: scale(1.14) translate(-1.5%, -1%);
	}
}

.bl-vp__shade {
	position: absolute;
	inset: 0;
	z-index: 1;
	background: linear-gradient(180deg, rgba(20, 15, 6, 0.55), rgba(20, 15, 6, 0) 22%, rgba(20, 15, 6, 0) 52%, rgba(20, 15, 6, 0.82));
	pointer-events: none;
}

/* story-style progress, one segment per item */
.bl-vp__segs {
	position: absolute;
	top: 12px;
	right: 14px;
	left: 14px;
	z-index: 4;
	display: flex;
	gap: 4px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.bl-vp__segs li {
	position: relative;
	flex: 1;
	height: 2.5px;
	overflow: hidden;
	border-radius: 2px;
	background: rgba(255, 255, 255, 0.3);
}

.bl-vp__segs li > i {
	position: absolute;
	inset: 0;
	display: block;
	background: #fff;
	transform: scaleX(0);
	transform-origin: left;
}

.bl-vp__segs li.is-done > i {
	transform: scaleX(1);
}

.bl-vp__top {
	position: absolute;
	top: 26px;
	right: 14px;
	left: 14px;
	z-index: 4;
	display: flex;
	align-items: center;
	gap: 8px;
}

.bl-vp__brand img {
	display: block;
	filter: brightness(0) invert(1);
	opacity: 0.95;
}

.bl-vp__title {
	flex: 1;
	min-width: 0;
	overflow: hidden;
	color: rgba(255, 255, 255, 0.8);
	font: 400 11px/1 var(--bl-sans);
	letter-spacing: 0.08em;
	text-overflow: ellipsis;
	text-transform: uppercase;
	white-space: nowrap;
}

.bl-vp__ctl {
	display: grid;
	place-items: center;
	width: 34px;
	height: 34px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.14);
	-webkit-backdrop-filter: blur(8px);
	backdrop-filter: blur(8px);
	color: #fff;
	cursor: pointer;
	transition: background-color 0.2s ease;
}

.bl-vp__ctl:hover {
	background: rgba(255, 255, 255, 0.3);
}

.bl-vp__ctl {
	line-height: 0; /* the icons sit in inline wrappers: without this they ride 3px above the centre */
}

.bl-vp__ctl svg {
	display: block;
	width: 16px;
	height: 16px;
}

.bl-vp__ico-play,
.bl-vp__ico-on {
	display: none;
}

.bl-vp.is-paused .bl-vp__ico-play,
.bl-vp.is-sound .bl-vp__ico-on {
	display: grid;
}

.bl-vp.is-paused .bl-vp__ico-pause,
.bl-vp.is-sound .bl-vp__ico-off {
	display: none;
}

/* the whole picture is the play / pause target */
.bl-vp__tap {
	position: absolute;
	inset: 60px 0 190px;
	z-index: 3;
	padding: 0;
	border: 0;
	background: none;
	cursor: pointer;
}

.bl-vp__flash {
	position: absolute;
	top: 42%;
	left: 50%;
	z-index: 4;
	width: 64px;
	height: 64px;
	margin: -32px 0 0 -32px;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.22);
	-webkit-backdrop-filter: blur(6px);
	backdrop-filter: blur(6px);
	opacity: 0;
	pointer-events: none;
}

.bl-vp__flash.is-on {
	animation: bl-vp-flash 0.6s ease-out;
}

@keyframes bl-vp-flash {
	0% {
		opacity: 0.9;
		transform: scale(0.7);
	}
	100% {
		opacity: 0;
		transform: scale(1.5);
	}
}

/* overlay inside the stage (phones; desktop shows the side panel instead) */
.bl-vp__over {
	position: absolute;
	right: 0;
	bottom: 0;
	left: 0;
	z-index: 5;
	padding: 0 12px 16px;
}

.bl-vp__products {
	display: flex;
	gap: 10px;
	margin: 0 0 10px;
	padding: 0 2px 2px;
	overflow-x: auto;
	list-style: none;
	scroll-snap-type: x mandatory;
	scrollbar-width: none;
}

.bl-vp__products::-webkit-scrollbar {
	display: none;
}

.bl-vp__p {
	flex: none;
	scroll-snap-align: start;
	width: min(236px, 74%);
	animation: bl-vp-rise 0.5s cubic-bezier(0.2, 0.8, 0.2, 1) both;
	animation-delay: calc(var(--i, 0) * 70ms + 150ms);
}

@keyframes bl-vp-rise {
	from {
		opacity: 0;
		transform: translateY(14px);
	}
}

/* product card: glass tile, photo, name, price and a quick add */
.bl-vp-card {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 8px 8px 8px 8px;
	border: 1px solid rgba(255, 255, 255, 0.35);
	border-radius: 18px;
	background: rgba(247, 244, 238, 0.82);
	-webkit-backdrop-filter: blur(14px) saturate(1.3);
	backdrop-filter: blur(14px) saturate(1.3);
	color: var(--bl-brand);
	text-decoration: none;
	transition: background-color 0.25s ease, transform 0.25s ease;
}

.bl-vp-card:hover {
	background: rgba(247, 244, 238, 0.97);
	transform: translateY(-2px);
}

.bl-vp-card__img {
	flex: none;
	width: 54px;
	height: 68px;
	overflow: hidden;
	border-radius: 11px;
	background: #fff;
}

.bl-vp-card__img img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.bl-vp-card__txt {
	flex: 1;
	min-width: 0;
}

.bl-vp-card__name {
	display: block;
	overflow: hidden;
	font: 400 16px/1.2 var(--bl-serif);
	text-overflow: ellipsis;
	white-space: nowrap;
}

.bl-vp-card__price {
	display: block;
	margin-top: 4px;
	color: var(--bl-brand-2);
	font: 400 12px/1.2 var(--bl-sans);
}

.bl-vp-card__add {
	display: grid;
	place-items: center;
	flex: none;
	width: 34px;
	height: 34px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: var(--bl-btn-bg);
	color: var(--bl-brand);
	cursor: pointer;
	transition: background-color 0.2s ease, transform 0.25s cubic-bezier(0.2, 1.4, 0.3, 1);
}

.bl-vp-card__add:hover {
	background: var(--bl-brand-2);
	transform: scale(1.1);
}

.bl-vp-card__add.is-busy {
	opacity: 0.6;
}

.bl-vp-card__add.is-done {
	background: #4d7a4a;
}

.bl-vp__cta {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	height: 44px;
	border: 1px solid rgba(255, 255, 255, 0.7);
	border-radius: 9999px;
	background: rgba(255, 255, 255, 0.14);
	-webkit-backdrop-filter: blur(8px);
	backdrop-filter: blur(8px);
	color: #fff;
	font: 400 12px/1 var(--bl-sans);
	letter-spacing: 0.08em;
	text-decoration: none;
	text-transform: uppercase;
	transition: background-color 0.25s ease, color 0.25s ease;
}

.bl-vp__cta:hover {
	background: #fff;
	color: var(--bl-brand);
}

.bl-vp__cta[hidden] {
	display: none;
}

/* side panel, desktop only */
.bl-vp__side {
	display: none;
}

.bl-vp__round {
	position: absolute;
	z-index: 6;
	display: grid;
	place-items: center;
	width: 46px;
	height: 46px;
	padding: 0;
	border: 1px solid rgba(255, 255, 255, 0.4);
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.12);
	-webkit-backdrop-filter: blur(10px);
	backdrop-filter: blur(10px);
	color: #fff;
	cursor: pointer;
	transition: background-color 0.25s ease, color 0.25s ease, transform 0.25s ease;
}

.bl-vp__round:hover {
	background: #fff;
	color: var(--bl-brand);
}

.bl-vp__close {
	top: 22px;
	right: 22px;
}

.bl-vp__prev,
.bl-vp__next {
	top: 50%;
	margin-top: -23px;
}

.bl-vp__prev {
	left: calc(50% - 280px);
}

.bl-vp__next {
	right: calc(50% - 280px);
}

@media (min-width: 1100px) {
	.bl-vp__over .bl-vp__products,
	.bl-vp__over .bl-vp__cta {
		display: none;
	}
	.bl-vp__layout {
		justify-content: center;
		margin-left: 0;
	}
	.bl-vp__side {
		display: block;
		flex: none;
		width: 320px;
		padding: 26px 22px;
		border: 1px solid rgba(255, 255, 255, 0.28);
		border-radius: 26px;
		background: rgba(247, 244, 238, 0.1);
		-webkit-backdrop-filter: blur(22px) saturate(1.2);
		backdrop-filter: blur(22px) saturate(1.2);
		box-shadow: 0 40px 80px -40px rgba(0, 0, 0, 0.6);
	}
	.bl-vp__kicker {
		margin: 0 0 8px;
		color: rgba(255, 255, 255, 0.7);
		font: 400 11px/1 var(--bl-sans);
		letter-spacing: 0.08em;
		text-transform: uppercase;
	}
	.bl-vp__sidetitle {
		margin: 0 0 20px;
		color: #fff;
		font: 400 30px/1.15 var(--bl-serif);
	}
	.bl-vp__list {
		display: grid;
		grid-template-columns: minmax(0, 1fr); /* long names must shrink with an ellipsis, not widen the panel */
		gap: 10px;
		margin: 0 0 18px;
		padding: 0;
		list-style: none;
	}
	.bl-vp__list .bl-vp__p {
		width: auto;
		min-width: 0;
	}
	/* with any number of products the panel never outgrows the screen: the list scrolls inside it */
	.bl-vp__side {
		max-height: min(calc(100dvh - 96px), 820px);
		overflow-y: auto;
		overscroll-behavior: contain;
		scrollbar-width: thin;
		scrollbar-color: rgba(255, 255, 255, 0.4) transparent;
	}
	.bl-vp__cta--side {
		margin-top: 4px;
	}
	.bl-vp__prev {
		left: calc(50% - 466px);
	}
	.bl-vp__next {
		right: calc(50% - 466px);
	}
	.bl-vp__layout {
		transform: translateX(0);
	}
}

@media (max-width: 899px) {
	.bl-vp__layout {
		padding: 0;
	}
	.bl-vp__stage {
		width: 100vw;
		max-width: none;
		height: 100dvh;
		aspect-ratio: auto;
		border-radius: 0;
		box-shadow: none;
	}
	.bl-vp__prev,
	.bl-vp__next {
		display: none;
	}
	.bl-vp__close {
		top: 36px;
		right: 12px;
		width: 38px;
		height: 38px;
		border: 0;
		background: rgba(0, 0, 0, 0.28);
	}
	.bl-vp__top {
		right: 60px;
		top: 24px;
	}
	.bl-vp__segs {
		top: 10px;
	}
}

@media (min-width: 900px) and (max-width: 1099px) {
	.bl-vp__prev {
		left: calc(50% - 280px);
	}
	.bl-vp__next {
		right: calc(50% - 280px);
	}
}

@media (prefers-reduced-motion: reduce) {
	.bl-vp__backdrop,
	.bl-vp__p,
	.bl-vp.is-story .bl-vp__still {
		animation: none;
	}
}


/* share confirmation ("link copied") */
.bl-vp__toast {
	position: absolute;
	top: 64px;
	left: 50%;
	z-index: 6;
	padding: 8px 14px;
	border-radius: 9999px;
	background: rgba(0, 0, 0, 0.7);
	color: #fff;
	font: 400 12px/1.2 var(--bl-sans);
	letter-spacing: 0.02em;
	max-width: 92%;
	overflow-wrap: anywhere;
	text-align: center;
	user-select: all;
	transform: translateX(-50%);
	pointer-events: none;
}

.bl-vp__toast.is-on {
	animation: bl-vp-toast 2.2s ease both;
}

@keyframes bl-vp-toast {
	0% { opacity: 0; transform: translate(-50%, -6px); }
	12%, 80% { opacity: 1; transform: translate(-50%, 0); }
	100% { opacity: 0; }
}

/* a photo from the footer has no products: no side panel, the stage stays in the middle */
@media (min-width: 1100px) {
	.bl-vp.no-products .bl-vp__side { display: none; }
	.bl-vp.no-products .bl-vp__prev { left: calc(50% - 280px); }
	.bl-vp.no-products .bl-vp__next { right: calc(50% - 280px); }
}
