@import url('https://fonts.googleapis.com/css2?family=Vazirmatn:wght@400;600;700&display=swap');

/* Teaching Sample Showcase Frontend Styles */
.tss-container {
	--tss-ink: #1f2937;
	--tss-muted: #6b7280;
	--tss-accent: #b15ff3;
	--tss-surface: #e5ccfb;
	--tss-panel: #ffffff;

	display: flex;
	flex-direction: row-reverse;
	gap: 32px;
	width: 1216px;
	height: 498.837px;
	max-width: 100%;
	margin: 24px auto;
	padding: 24px;
	border-radius: 42px;
	background: var(--tss-surface);
	direction: rtl;
	text-align: right;
	font-family: "Vazirmatn", "Tahoma", sans-serif;
	color: var(--tss-ink);
	align-items: flex-start;
	position: relative;
	overflow: hidden;
	box-sizing: border-box;
	animation: tss-enter 0.6s ease both;
}

.tss-container * {
	box-sizing: border-box;
}

.tss-main-column {
	width: 717.6825px;
	max-width: 100%;
	display: flex;
	flex-direction: column;
	gap: 12px;
	flex: 0 1 auto;
	min-width: 0;
}

.tss-video-player-wrapper {
	background: transparent;
	padding: 0;
}

.tss-main-video-shell {
	position: relative;
	display: flex;
	justify-content: center;
	align-items: center;
}

.tss-main-player {
	width: 100%;
	height: 325px;
	max-width: 100%;
	background: #0b0d10;
	border-radius: 36px;
	border: 2px solid var(--tss-accent);
	box-shadow: 0 12px 28px rgba(15, 23, 42, 0.18);
	object-fit: cover;
}

.tss-main-play-icon {
	position: absolute;
	left: 50%;
	top: 50%;
	transform: translate(-50%, -50%);
	width: 84px;
	height: 84px;
	border-radius: 999px;
	background: transparent;
	background-image: url("../../play-circle.svg");
	background-repeat: no-repeat;
	background-position: center;
	background-size: contain;
	box-shadow: 0 12px 24px rgba(15, 23, 42, 0.25);
	opacity: 0.92;
	pointer-events: none;
	transition: opacity 0.2s ease;
}

.tss-main-video-shell.tss-is-playing .tss-main-play-icon {
	opacity: 0;
	visibility: hidden;
}

.tss-carousel-wrapper {
	width: 100%;
	height: 104px;
	background: transparent;
	border-radius: 24px;
	padding: 0;
	overflow: hidden;
}

.tss-carousel {
	height: 100%;
	display: flex;
	flex-direction: row;
	gap: 12px;
	align-items: center;
	overflow-x: auto;
	overflow-y: hidden;
	scroll-snap-type: x proximity;
	scrollbar-gutter: stable;
	scrollbar-color: rgba(31, 41, 55, 0.45) transparent;
	direction: ltr;
	padding: 8px 4px;
}

.tss-carousel-item {
	position: relative;
	cursor: pointer;
	width: 140px;
	height: 80px;
	border-radius: 18px;
	overflow: hidden;
	border: 1px solid transparent;
	background: var(--tss-panel);
	box-shadow: 0 8px 18px rgba(15, 23, 42, 0.1);
	transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
	scroll-snap-align: start;
	flex: 0 0 auto;
}

.tss-carousel-item:hover {
	transform: translateY(-2px);
	box-shadow: 0 12px 24px rgba(15, 23, 42, 0.16);
}

.tss-carousel-item.active {
	border-color: var(--tss-accent);
	box-shadow: 0 0 0 2px rgba(177, 95, 243, 0.28), 0 12px 24px rgba(15, 23, 42, 0.16);
}

.tss-carousel-item img,
.tss-placeholder-thumbnail {
	width: 100%;
	height: 100%;
	display: block;
	object-fit: cover;
}

.tss-carousel-item video:not(.tss-inline-player) {
	width: 100%;
	height: 100%;
	display: none;
	object-fit: cover;
	pointer-events: none;
}

.tss-placeholder-thumbnail {
	background: rgba(255, 255, 255, 0.7);
	display: flex;
	align-items: center;
	justify-content: center;
	text-align: center;
	padding: 8px;
	color: var(--tss-muted);
	font-weight: 600;
	font-size: 0.85rem;
	direction: rtl;
}

.tss-thumbnail-overlay {
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, rgba(15, 23, 42, 0.08), rgba(15, 23, 42, 0.4));
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 0.85;
	transition: opacity 0.2s ease-in-out;
}

.tss-carousel-item:hover .tss-thumbnail-overlay {
	opacity: 1;
}

.tss-play-icon {
	width: 36px;
	height: 36px;
	background: transparent;
	border-radius: 0;
	background-image: url("../../play-circle.svg");
	background-repeat: no-repeat;
	background-position: center;
	background-size: contain;
}

.tss-play-icon::before {
	content: none;
}

.tss-carousel-media {
	position: relative;
	width: 100%;
	height: 100%;
	border-radius: 18px;
	overflow: hidden;
	background: #0b0d10;
}

.tss-carousel-details {
	display: none;
	flex-direction: column;
	gap: 6px;
}

.tss-carousel-title {
	display: block;
	font-size: 1rem;
	font-weight: 700;
	color: var(--tss-ink);
}

.tss-carousel-description {
	display: block;
	font-size: 0.95rem;
	line-height: 1.6;
	color: var(--tss-muted);
}

.tss-carousel-description:empty {
	display: none;
}

.tss-info-column {
	width: 418px;
	max-width: 100%;
	display: flex;
	flex-direction: column;
	gap: 24px;
	flex: 0 1 auto;
	min-width: 0;
}

.tss-info-image-wrapper {
	width: 418.318px;
	max-width: 100%;
	height: 235.837px;
	border-radius: 36px;
	border: 2px solid var(--tss-accent);
	overflow: hidden;
	background: rgba(255, 255, 255, 0.7);
	display: flex;
	align-items: center;
	justify-content: center;
}

.tss-info-image {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.tss-info-image-placeholder {
	width: 100%;
	height: 100%;
	background: rgba(255, 255, 255, 0.6);
}

.tss-info-image-wrapper.tss-no-image .tss-info-image {
	display: none;
}

.tss-info-image-wrapper.tss-has-image .tss-info-image-placeholder {
	display: none;
}

.tss-info-text {
	width: 417px;
	max-width: 100%;
	height: 203px;
	display: flex;
	flex-direction: column;
	gap: 24px;
}

.tss-main-video-title {
	margin: 0;
	font-size: 1.15rem;
	font-weight: 700;
	color: var(--tss-ink);
	letter-spacing: -0.2px;
}

.tss-info-description-block {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.tss-info-label {
	font-weight: 600;
	font-size: 16px;
	color: var(--tss-ink);
}

.tss-info-description {
	margin: 0;
	font-family: "Dana", "Vazirmatn", "Tahoma", sans-serif;
	font-weight: 400;
	font-size: 16px;
	line-height: 1.6;
	color: var(--tss-ink);
}

.tss-info-description:empty {
	display: none;
}

.tss-carousel::-webkit-scrollbar {
	height: 8px;
}

.tss-carousel::-webkit-scrollbar-thumb {
	background: rgba(31, 41, 55, 0.4);
	border-radius: 999px;
}

.tss-carousel::-webkit-scrollbar-track {
	background: transparent;
}

@keyframes tss-enter {
	from {
		opacity: 0;
		transform: translateY(12px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

.tss-container.tss-is-mobile {
	flex-direction: column;
	height: auto;
	gap: 20px;
	padding: 16px;
	border-radius: 28px;
	overflow: visible;
	background: transparent;
	box-shadow: none;
}

.tss-container.tss-is-mobile .tss-main-column,
.tss-container.tss-is-mobile .tss-info-column,
.tss-container.tss-is-mobile .tss-info-text,
.tss-container.tss-is-mobile .tss-info-image-wrapper {
	width: 100%;
}

.tss-container.tss-is-mobile .tss-main-player {
	height: auto;
	aspect-ratio: 16 / 9;
}

.tss-container.tss-is-mobile .tss-video-player-wrapper {
	display: none;
}

.tss-container.tss-is-mobile .tss-carousel-wrapper {
	background: transparent;
	height: auto;
	padding: 0;
	overflow: visible;
}

.tss-container.tss-is-mobile .tss-carousel {
	flex-direction: row;
	gap: 12px;
	overflow-x: auto;
	overflow-y: hidden;
	scroll-snap-type: x proximity;
	scrollbar-gutter: stable;
	scrollbar-color: rgba(31, 41, 55, 0.45) transparent;
	direction: rtl;
	padding: 12px 6px;
}

.tss-container.tss-is-mobile .tss-carousel-item {
	width: 332px;
	min-width: 332px;
	max-width: 332px;
	height: 370px;
	display: flex;
	flex-direction: column;
	gap: 12px;
	padding: 12px;
	border-radius: 24px;
	border: 2px solid transparent;
	background: #b15ff3;
	box-shadow: 0 14px 28px rgba(15, 23, 42, 0.12);
	flex: 0 0 auto;
	scroll-snap-align: start;
}

.tss-container.tss-is-mobile .tss-carousel-media {
	aspect-ratio: 16 / 9;
	width: 100%;
	height: 150px;
	min-height: 150px;
	background: #0b0d10;
	border-radius: 24px;
	border: 2px solid #ffffff;
	overflow: hidden;
}

.tss-container.tss-is-mobile .tss-carousel-details {
	display: flex;
	min-height: 96px;
	color: #ffffff;
}

.tss-container.tss-is-mobile .tss-carousel-title,
.tss-container.tss-is-mobile .tss-carousel-description {
	color: #ffffff;
}

.tss-container.tss-is-mobile .tss-carousel-item .tss-thumbnail-overlay {
	display: flex;
}

.tss-container.tss-is-mobile .tss-carousel-item.tss-inline-playing .tss-thumbnail-overlay {
	display: none;
}

.tss-container.tss-is-mobile .tss-info-text {
	height: auto;
}

.tss-container.tss-is-mobile .tss-info-column {
	display: none;
}

.tss-container.tss-is-mobile .tss-carousel-item .tss-inline-player {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	border-radius: 18px;
	background: #000;
	pointer-events: auto;
}

.tss-container.tss-is-mobile .tss-carousel-item.tss-inline-playing img,
.tss-container.tss-is-mobile .tss-carousel-item.tss-inline-playing .tss-placeholder-thumbnail,
.tss-container.tss-is-mobile .tss-carousel-item.tss-inline-playing .tss-thumbnail-overlay {
	display: none;
}

@media (prefers-reduced-motion: reduce) {
	.tss-container,
	.tss-carousel-item {
		animation: none;
	}

	.tss-carousel-item {
		transition: none;
	}
}

