/*!
 * Bölcső Videotár – frontend
 * Testreszabás: a lenti --bvt-* változók felülírhatók pl. a Divi témabeállítások egyedi CSS-ében.
 */
.bvt {
	--bvt-accent: #6b7a59;
	--bvt-accent-contrast: #fff;
	--bvt-accent-soft: rgba(107, 122, 89, 0.12);
	--bvt-gold: #c9a24a;
	--bvt-text: #2b2a28;
	--bvt-muted: #6f6c66;
	--bvt-card: #fff;
	--bvt-hover: #f7f5ef;
	--bvt-radius: 28px;
	--bvt-radius-sm: 14px;
	--bvt-shadow: 0 14px 34px -14px rgba(52, 46, 30, 0.22), 0 2px 8px rgba(52, 46, 30, 0.05);
	--bvt-list-width: 380px;
	--bvt-gap: 28px;

	container: bvt / inline-size;
	position: relative;
	box-sizing: border-box;
	margin: 0 0 2.5em;
	color: var(--bvt-text);
	line-height: 1.5;
}

@supports (color: color-mix(in srgb, red 50%, blue)) {
	.bvt {
		--bvt-accent-soft: color-mix(in srgb, var(--bvt-accent) 12%, transparent);
	}
}

.bvt *,
.bvt *::before,
.bvt *::after {
	box-sizing: border-box;
}

.bvt [hidden] {
	display: none !important;
}

/* Téma-reset (Divi és egyéb globális gomb/lista stílusok ellen) */
.bvt button {
	appearance: none;
	-webkit-appearance: none;
	margin: 0;
	padding: 0;
	border: 0;
	background: none;
	box-shadow: none;
	color: inherit;
	font: inherit;
	letter-spacing: inherit;
	text-transform: none;
	text-align: inherit;
	cursor: pointer;
}

.bvt img {
	max-width: none;
	border: 0;
}

.bvt img.is-broken {
	visibility: hidden;
}

.bvt .bvt__sr {
	position: absolute !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
}

/* ---------- Fejléc ---------- */
.bvt .bvt__header {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: space-between;
	gap: 8px 20px;
	margin: 0 0 20px;
	padding: 0 6px;
}

.bvt .bvt__heading {
	margin: 0;
	padding: 0;
	font-size: clamp(1.6rem, 1.2rem + 1.4vw, 2.25rem);
	line-height: 1.15;
	color: var(--bvt-text);
}

.bvt .bvt__count {
	font-size: 0.78rem;
	font-weight: 700;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--bvt-accent);
}

/* ---------- Elrendezés ---------- */
.bvt .bvt__layout {
	display: grid;
	grid-template-columns: minmax(260px, var(--bvt-list-width)) minmax(0, 1fr);
	grid-template-areas: "list player";
	gap: var(--bvt-gap);
	align-items: stretch;
}

.bvt.bvt--list-right .bvt__layout {
	grid-template-columns: minmax(0, 1fr) minmax(260px, var(--bvt-list-width));
	grid-template-areas: "player list";
}

.bvt .bvt__player-card,
.bvt .bvt__list-card {
	background: var(--bvt-card);
	border-radius: var(--bvt-radius);
	box-shadow: var(--bvt-shadow);
	overflow: hidden;
}

.bvt .bvt__player-card {
	grid-area: player;
	display: flex;
	flex-direction: column;
	scroll-margin-top: 110px;
}

.bvt .bvt__list-card {
	grid-area: list;
	position: relative;
	min-height: 360px;
}

/* ---------- Lejátszó ---------- */
.bvt .bvt__media {
	position: relative;
	aspect-ratio: 16 / 9;
	background: #1f1e1b;
	overflow: hidden;
}

@supports not (aspect-ratio: 16 / 9) {
	.bvt .bvt__media {
		height: 0;
		padding-top: 56.25%;
	}
}

.bvt .bvt__facade,
.bvt .bvt__iframe {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: 0;
}

.bvt .bvt__facade {
	display: block;
	overflow: hidden;
}

.bvt .bvt__facade::after {
	content: "";
	position: absolute;
	inset: 0;
	background: radial-gradient(ellipse at center, rgba(0, 0, 0, 0) 40%, rgba(0, 0, 0, 0.28) 100%);
	transition: background-color 0.3s ease;
	pointer-events: none;
}

.bvt .bvt__poster {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.7s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.bvt .bvt__facade:hover .bvt__poster,
.bvt .bvt__facade:focus-visible .bvt__poster {
	transform: scale(1.035);
}

.bvt .bvt__play {
	position: absolute;
	top: 50%;
	left: 50%;
	z-index: 1;
	display: grid;
	place-items: center;
	width: clamp(58px, 9cqi, 84px);
	height: clamp(58px, 9cqi, 84px);
	border-radius: 50%;
	background: var(--bvt-accent);
	color: var(--bvt-accent-contrast);
	box-shadow: 0 0 0 10px rgba(255, 255, 255, 0.28), 0 12px 30px rgba(0, 0, 0, 0.3);
	transform: translate(-50%, -50%);
	transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.bvt .bvt__play svg {
	width: 42%;
	height: 42%;
	margin-left: 6%;
	fill: currentColor;
}

.bvt .bvt__facade:hover .bvt__play,
.bvt .bvt__facade:focus-visible .bvt__play {
	transform: translate(-50%, -50%) scale(1.07);
	box-shadow: 0 0 0 14px rgba(255, 255, 255, 0.32), 0 14px 34px rgba(0, 0, 0, 0.32);
}

.bvt .bvt__info {
	padding: 24px 30px 28px;
}

.bvt .bvt__meta {
	display: flex;
	flex-wrap: wrap;
	gap: 6px 14px;
	margin: 0 0 8px;
	padding: 0;
	font-size: 0.78rem;
	font-weight: 700;
	letter-spacing: 0.13em;
	text-transform: uppercase;
	color: var(--bvt-muted);
}

.bvt .bvt__meta-duration::before {
	content: "";
	display: inline-block;
	width: 4px;
	height: 4px;
	margin: 0 14px 0 0;
	border-radius: 50%;
	background: var(--bvt-gold);
	vertical-align: middle;
	position: relative;
	top: -1px;
}

.bvt .bvt__title {
	margin: 0 0 20px;
	padding: 0;
	font-size: clamp(1.3rem, 1.05rem + 0.9vw, 1.8rem);
	line-height: 1.25;
	color: var(--bvt-text);
}

.bvt .bvt__nav {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px;
}

.bvt .bvt__btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	min-height: 44px;
	padding: 10px 20px;
	border: 2px solid var(--bvt-accent);
	border-radius: 999px;
	background: var(--bvt-accent);
	color: var(--bvt-accent-contrast);
	font-size: 0.95rem;
	font-weight: 600;
	line-height: 1;
	transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease, opacity 0.2s ease;
}

.bvt .bvt__btn svg {
	width: 18px;
	height: 18px;
	fill: none;
	stroke: currentColor;
	stroke-width: 2.4;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.bvt .bvt__btn--ghost {
	background: transparent;
	color: var(--bvt-accent);
}

.bvt .bvt__btn:hover:not(:disabled) {
	transform: translateY(-1px);
}

.bvt .bvt__btn--ghost:hover:not(:disabled) {
	background: var(--bvt-accent-soft);
}

.bvt .bvt__btn:disabled {
	opacity: 0.38;
	cursor: default;
}

.bvt .bvt__yt {
	margin-left: auto;
	font-size: 0.9rem;
	font-weight: 600;
	color: var(--bvt-muted);
	text-decoration: underline;
	text-decoration-color: var(--bvt-gold);
	text-decoration-thickness: 2px;
	text-underline-offset: 4px;
	transition: color 0.2s ease;
}

.bvt .bvt__yt:hover {
	color: var(--bvt-accent);
}

/* ---------- Lista ---------- */
.bvt .bvt__list {
	position: absolute;
	inset: 0;
	margin: 0;
	padding: 12px;
	list-style: none;
	overflow-y: auto;
	overscroll-behavior: contain;
	scrollbar-width: thin;
	scrollbar-color: var(--bvt-accent-soft) transparent;
	/* görgetési árnyék a lista tetején/alján */
	background:
		linear-gradient(var(--bvt-card) 30%, rgba(255, 255, 255, 0)) top / 100% 36px no-repeat local,
		linear-gradient(rgba(255, 255, 255, 0), var(--bvt-card) 70%) bottom / 100% 36px no-repeat local,
		radial-gradient(farthest-side at 50% 0, rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0)) top / 100% 12px no-repeat scroll,
		radial-gradient(farthest-side at 50% 100%, rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0)) bottom / 100% 12px no-repeat scroll;
	background-color: var(--bvt-card);
}

.bvt .bvt__item {
	margin: 0;
	padding: 0;
	list-style: none;
}

.bvt .bvt__item::before,
.bvt .bvt__item::marker {
	content: none;
}

.bvt .bvt__item + .bvt__item {
	margin-top: 4px;
}

.bvt .bvt__item-btn {
	position: relative;
	display: flex;
	align-items: center;
	gap: 14px;
	width: 100%;
	padding: 10px;
	border-radius: 18px;
	text-align: left;
	transition: background-color 0.2s ease;
}

.bvt .bvt__item-btn:hover {
	background: var(--bvt-hover);
}

.bvt .bvt__item-btn.is-active {
	background: var(--bvt-accent-soft);
}

.bvt .bvt__item-btn.is-active::before {
	content: "";
	position: absolute;
	top: 18px;
	bottom: 18px;
	left: 0;
	width: 4px;
	border-radius: 0 4px 4px 0;
	background: var(--bvt-accent);
}

.bvt .bvt__thumb {
	position: relative;
	flex: 0 0 120px;
	aspect-ratio: 16 / 9;
	border-radius: 12px;
	overflow: hidden;
	background: #e9e5db;
}

.bvt .bvt__thumb img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.4s ease;
}

.bvt .bvt__item-btn:hover .bvt__thumb img {
	transform: scale(1.06);
}

.bvt .bvt__dur {
	position: absolute;
	right: 6px;
	bottom: 6px;
	padding: 2px 6px;
	border-radius: 6px;
	background: rgba(20, 20, 18, 0.78);
	color: #fff;
	font-size: 0.7rem;
	font-weight: 700;
	line-height: 1.4;
	letter-spacing: 0.02em;
}

.bvt .bvt__watched {
	position: absolute;
	top: 6px;
	left: 6px;
	display: none;
	place-items: center;
	width: 22px;
	height: 22px;
	border-radius: 50%;
	background: var(--bvt-accent);
	color: #fff;
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
}

.bvt .bvt__watched svg {
	width: 14px;
	height: 14px;
	fill: none;
	stroke: currentColor;
	stroke-width: 3;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.bvt .bvt__item-btn.is-watched .bvt__watched {
	display: grid;
}

.bvt .bvt__item-text {
	display: flex;
	flex-direction: column;
	gap: 4px;
	min-width: 0;
}

.bvt .bvt__item-title {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 3;
	overflow: hidden;
	font-size: 0.93rem;
	font-weight: 600;
	line-height: 1.35;
	color: var(--bvt-text);
}

.bvt .bvt__now {
	display: none;
	font-size: 0.68rem;
	font-weight: 700;
	letter-spacing: 0.13em;
	text-transform: uppercase;
	color: var(--bvt-accent);
}

.bvt .bvt__item-btn.is-active .bvt__now {
	display: block;
}

/* ---------- Fókusz ---------- */
.bvt button:focus-visible,
.bvt a:focus-visible {
	outline: 3px solid var(--bvt-accent);
	outline-offset: 2px;
}

.bvt .bvt__facade:focus-visible {
	outline-offset: -6px;
	outline-color: #fff;
}

.bvt .bvt__item-btn:focus-visible {
	outline-offset: -3px;
}

/* ---------- Reszponzív: viewport (régi böngészőknek) ---------- */
@media (max-width: 900px) {
	.bvt .bvt__layout,
	.bvt.bvt--list-right .bvt__layout {
		grid-template-columns: minmax(0, 1fr);
		grid-template-areas: "player" "list";
		gap: 20px;
	}

	.bvt .bvt__list-card {
		min-height: 0;
	}

	.bvt .bvt__list {
		position: static;
		max-height: min(28rem, 70vh);
	}
}

/* ---------- Reszponzív: a beillesztett hely szélessége alapján (pl. keskeny Divi oszlop) ---------- */
@container bvt (max-width: 760px) {
	.bvt__layout,
	.bvt--list-right .bvt__layout {
		grid-template-columns: minmax(0, 1fr) !important;
		grid-template-areas: "player" "list" !important;
		gap: 20px;
	}

	.bvt__list-card {
		min-height: 0 !important;
	}

	.bvt__list {
		position: static !important;
		max-height: min(28rem, 70vh);
	}
}

@container bvt (max-width: 520px) {
	.bvt__player-card,
	.bvt__list-card {
		border-radius: 20px !important;
	}

	.bvt__info {
		padding: 18px 18px 22px !important;
	}

	.bvt__thumb {
		flex-basis: 100px !important;
	}

	.bvt__list {
		padding: 8px !important;
	}

	.bvt__btn {
		flex: 1 1 0;
		justify-content: center;
		padding: 10px 14px !important;
	}

	.bvt__yt {
		flex: 1 1 100%;
		margin: 4px 0 0 !important;
		text-align: center;
	}
}

@media (max-width: 520px) {
	.bvt .bvt__player-card,
	.bvt .bvt__list-card {
		border-radius: 20px;
	}

	.bvt .bvt__info {
		padding: 18px 18px 22px;
	}

	.bvt .bvt__thumb {
		flex-basis: 100px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.bvt *,
	.bvt *::before,
	.bvt *::after {
		transition: none !important;
	}
}
