.ueps-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 30rem));
	justify-content: center;
	align-content: start;
	gap: 0.85rem 1.15rem;
	width: min(100%, 66rem);
	max-width: 66rem;
	height: 100%;
	min-height: 0;
	margin-inline: auto;
	padding: 1rem 1.5rem 1.25rem;
	overflow-x: hidden;
	overflow-y: auto;
	box-sizing: border-box;
	scrollbar-width: thin;
	scrollbar-color: rgba(232, 217, 184, 0.45) transparent;
}

.ueps-card {
	display: grid;
	grid-template-columns: auto minmax(0, 1fr);
	gap: 0.65rem;
	align-items: center;
	min-height: 0;
	padding: 0.5rem 0.7rem 0.5rem 0.5rem;
	border: 1px solid rgba(232, 217, 184, 0.18);
	border-radius: 0.9rem;
	background: rgba(4, 22, 20, 0.42);
	color: #fff;
	text-decoration: none;
	transition: border-color 0.18s ease, background-color 0.18s ease, transform 0.18s ease;
}

.ueps-card:hover,
.ueps-card:focus-visible {
	border-color: rgba(232, 217, 184, 0.55);
	background: rgba(8, 40, 36, 0.72);
	outline: none;
	transform: translateY(-1px);
}

.ueps-card__media {
	display: block;
	width: clamp(4.4rem, 8vh, 5.6rem);
	height: clamp(4.4rem, 8vh, 5.6rem);
	border-radius: 0.72rem;
	overflow: hidden;
	flex-shrink: 0;
	background: rgba(255, 255, 255, 0.06);
}

.ueps-card__img,
.ueps-card__placeholder {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.ueps-card__placeholder {
	background: linear-gradient(135deg, #0b3d38, #14524b);
}

.ueps-card__copy {
	display: flex;
	flex-direction: column;
	gap: 0.22rem;
	min-width: 0;
}

.ueps-card__title {
	font-size: clamp(0.88rem, 1.5vw, 1.05rem);
	font-weight: 800;
	line-height: 1.2;
	color: #fff;
}

.ueps-card__desc {
	font-size: 0.78rem;
	line-height: 1.35;
	color: rgba(255, 255, 255, 0.72);
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.ueps-card__cta {
	margin-top: 0.12rem;
	font-size: 0.68rem;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: #e8d9b8;
}

/* Ficha / capítulos */
.ueps-show-page {
	display: flex;
	flex-direction: column;
	min-height: 0;
	height: 100%;
}

.ueps-show,
.ueps-show__stage {
	display: grid;
	min-height: 0;
	height: 100%;
}

.ueps-show {
	position: relative;
}

.ueps-show__stage {
	grid-template-columns: minmax(0, 1.45fr) minmax(22rem, 0.9fr);
	gap: 1.75rem 2.25rem;
	padding: 1.15rem clamp(1.75rem, 4vw, 3.5rem) 1.25rem;
	box-sizing: border-box;
}

.ueps-show__player {
	min-height: 0;
	height: 100%;
	border-radius: 1rem;
	overflow: hidden;
	background: #041614;
	border: 1px solid rgba(232, 217, 184, 0.16);
}

.ueps-show__frame {
	display: block;
	width: 100%;
	height: 100%;
	border: 0;
	background: #000;
}

.ueps-show__empty {
	display: flex;
	align-items: center;
	justify-content: center;
	height: 100%;
	padding: 1.5rem;
	color: rgba(255, 255, 255, 0.78);
	text-align: center;
}

.ueps-show__aside {
	display: flex;
	flex-direction: column;
	min-height: 0;
	gap: 0.85rem;
	padding: 0.15rem 0.15rem 0 0.1rem;
}

.ueps-show__head {
	display: grid;
	grid-template-columns: auto minmax(0, 1fr);
	grid-template-areas:
		"cover title"
		"desc desc";
	gap: 0.55rem 0.9rem;
	align-items: center;
	padding-bottom: 1rem;
	border-bottom: 1px solid rgba(232, 217, 184, 0.12);
}

.ueps-show__cover {
	grid-area: cover;
	width: 4.1rem;
	height: 4.1rem;
	border-radius: 0.75rem;
	object-fit: cover;
}

.ueps-show__title {
	grid-area: title;
	margin: 0;
	font-size: clamp(1.1rem, 1.9vw, 1.4rem);
	font-weight: 800;
	line-height: 1.2;
	color: #fff;
}

.ueps-show__desc {
	grid-area: desc;
	margin: 0;
	font-size: 0.8rem;
	line-height: 1.5;
	color: rgba(255, 255, 255, 0.78);
}

.ueps-show__list-toggle {
	display: none;
}

.ueps-show__list-label {
	margin: 0.15rem 0 0;
	font-size: 0.68rem;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: rgba(232, 217, 184, 0.78);
}

.ueps-sheet {
	display: flex;
	flex-direction: column;
	min-height: 0;
	flex: 1 1 auto;
}

.ueps-sheet__backdrop {
	display: none;
}

.ueps-sheet__panel {
	display: flex;
	flex-direction: column;
	min-height: 0;
	flex: 1 1 auto;
}

.ueps-sheet__bar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 0.75rem;
}

.ueps-sheet__close {
	display: none;
}

.ueps-episodes {
	margin: 0;
	padding: 0 0.2rem 0 0;
	list-style: none;
	overflow-y: auto;
	min-height: 0;
	flex: 1 1 auto;
	scrollbar-width: thin;
	scrollbar-color: rgba(232, 217, 184, 0.45) transparent;
}

.ueps-episodes li + li {
	margin-top: 0.55rem;
}

.ueps-episode {
	display: grid;
	grid-template-columns: 6.4rem minmax(0, 1fr);
	gap: 0.75rem;
	align-items: center;
	width: 100%;
	padding: 0.5rem 0.6rem;
	border: 1px solid transparent;
	border-radius: 0.85rem;
	background: rgba(4, 22, 20, 0.35);
	color: inherit;
	text-align: left;
	cursor: pointer;
}

.ueps-episode:hover,
.ueps-episode:focus-visible,
.ueps-episode.is-active {
	border-color: rgba(232, 217, 184, 0.45);
	background: rgba(8, 40, 36, 0.72);
	outline: none;
}

.ueps-episode__thumb {
	width: 6.4rem;
	height: 3.6rem;
	border-radius: 0.5rem;
	object-fit: cover;
	background: #041614;
}

.ueps-episode__copy {
	display: flex;
	flex-direction: column;
	gap: 0.28rem;
	min-width: 0;
}

.ueps-episode__name {
	font-size: 0.8rem;
	font-weight: 700;
	line-height: 1.3;
	color: #fff;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.ueps-episode__date {
	font-size: 0.68rem;
	color: rgba(232, 217, 184, 0.8);
}

@media (max-width: 900px) {
	.ueps-grid {
		grid-template-columns: minmax(0, 32rem);
		justify-content: center;
		padding-inline: 1.1rem;
	}

	.ueps-show__stage {
		grid-template-columns: 1fr;
		grid-template-rows: minmax(0, 1fr) auto;
		padding: 0.7rem 0.9rem 0.65rem;
		gap: 0.7rem;
	}

	.ueps-show__aside {
		gap: 0.55rem;
	}

	.ueps-show__head {
		padding-bottom: 0;
		border-bottom: 0;
		gap: 0.4rem 0.65rem;
	}

	.ueps-show__cover {
		width: 3.2rem;
		height: 3.2rem;
	}

	.ueps-show__title {
		font-size: 1.05rem;
	}

	.ueps-show__desc {
		font-size: 0.74rem;
		line-height: 1.4;
		display: -webkit-box;
		-webkit-line-clamp: 3;
		-webkit-box-orient: vertical;
		overflow: hidden;
	}

	.ueps-show__list-toggle {
		display: flex;
		align-items: center;
		justify-content: space-between;
		width: 100%;
		padding: 0.72rem 0.95rem;
		border: 1px solid rgba(232, 217, 184, 0.28);
		border-radius: 0.95rem;
		background: #0b2c28;
		color: #fff;
		font: inherit;
		cursor: pointer;
	}

	.ueps-show__list-toggle-text {
		font-size: 0.78rem;
		font-weight: 800;
		letter-spacing: 0.1em;
		text-transform: uppercase;
		color: #e8d9b8;
	}

	.ueps-show__list-count {
		display: inline-flex;
		align-items: center;
		justify-content: center;
		min-width: 1.7rem;
		height: 1.7rem;
		padding: 0 0.4rem;
		border-radius: 999px;
		background: rgba(232, 217, 184, 0.16);
		color: #e8d9b8;
		font-size: 0.72rem;
		font-weight: 700;
	}

	.ueps-sheet {
		position: absolute;
		inset: 0;
		z-index: 12;
		flex: none;
		pointer-events: none;
		visibility: hidden;
	}

	.ueps-sheet.is-open {
		pointer-events: auto;
		visibility: visible;
	}

	.ueps-sheet__backdrop {
		display: block;
		position: absolute;
		inset: 0;
		background: rgba(4, 22, 20, 0.55);
	}

	.ueps-sheet__panel {
		position: absolute;
		left: 0.65rem;
		right: 0.65rem;
		top: 0.55rem;
		bottom: 0.55rem;
		flex: none;
		padding: 0.75rem 0.7rem 0.7rem;
		border: 1px solid rgba(232, 217, 184, 0.2);
		border-radius: 1.05rem;
		background: #0b2c28;
		box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
		transform: translateY(1.25rem);
		opacity: 0;
		transition: transform 0.22s ease, opacity 0.22s ease;
	}

	.ueps-sheet.is-open .ueps-sheet__panel {
		transform: none;
		opacity: 1;
	}

	.ueps-sheet__bar {
		padding: 0 0.15rem 0.65rem;
		border-bottom: 1px solid rgba(232, 217, 184, 0.12);
		margin-bottom: 0.55rem;
	}

	.ueps-sheet__close {
		display: inline-flex;
		align-items: center;
		padding: 0.25rem 0.55rem;
		border: 0;
		border-radius: 999px;
		background: rgba(255, 255, 255, 0.08);
		color: rgba(255, 255, 255, 0.88);
		font-size: 0.72rem;
		font-weight: 700;
		letter-spacing: 0.06em;
		text-transform: uppercase;
		cursor: pointer;
	}

	.ueps-episodes {
		padding-right: 0.15rem;
	}
}

@media (prefers-reduced-motion: reduce) {
	.ueps-card,
	.ueps-sheet__panel {
		transition: none;
	}
}
