.storyman-circle:focus-visible,
.storyman-popup-close:focus-visible,
.storyman-nav-arrow:focus-visible,
.storyman-play-pause:focus-visible,
.storyman-media-link:focus-visible,
.storyman-cta a:focus-visible {
	outline: 2px solid #fff;
	outline-offset: 2px;
}

.storyman-circle:focus-visible .storyman-ring {
	outline: 2px solid #000;
	outline-offset: 2px;
}

.storyman-sr-only {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect( 0, 0, 0, 0 );
	white-space: nowrap;
	border: 0;
}

.storyman-track {
	display: flex;
	gap: 16px;
	overflow-x: auto;
	padding: 8px 2px;
	scrollbar-width: thin;
}

.storyman-circle {
	background: transparent;
	border: 0;
	border-radius: 0;
	box-shadow: none;
	color: inherit;
	cursor: pointer;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 6px;
	flex: 0 0 auto;
	width: 84px;
	font-family: inherit;
	letter-spacing: normal;
	text-transform: none;
	-webkit-tap-highlight-color: transparent;
	-webkit-appearance: none;
	appearance: none;
	padding: 0;
}

.storyman-track .storyman-circle:hover,
.storyman-track .storyman-circle:focus,
.storyman-track .storyman-circle:active {
	background: transparent;
	border: 0;
	box-shadow: none;
	color: inherit;
	text-decoration: none;
}

.storyman-ring {
	position: relative;
	width: 72px;
	height: 72px;
	border-radius: 50%;
	padding: 3px;
	background: var( --storyman-ring-color, #e1306c );
	display: flex;
	align-items: center;
	justify-content: center;
}

.storyman-ring::after {
	content: "";
	position: absolute;
	inset: -5px;
	border-radius: 50%;
	background: var( --storyman-ring-color, #e1306c );
	-webkit-mask:
		repeating-conic-gradient( #000 0 20deg, transparent 20deg 40deg ),
		radial-gradient( farthest-side, transparent calc( 100% - 2px ), #000 calc( 100% - 2px ) );
	-webkit-mask-composite: source-in;
	mask:
		repeating-conic-gradient( #000 0 20deg, transparent 20deg 40deg ),
		radial-gradient( farthest-side, transparent calc( 100% - 2px ), #000 calc( 100% - 2px ) );
	mask-composite: intersect;
	opacity: 0;
	transition: opacity 0.2s ease;
	pointer-events: none;
}

.storyman-circle.is-seen .storyman-ring::after {
	background: var( --storyman-seen-ring-color, #c7c7c7 );
}

@media ( hover: hover ) {
	.storyman-track .storyman-circle:hover .storyman-ring::after {
		opacity: 1;
		animation: storyman-ring-spin 3s linear infinite;
	}
}

.storyman-track .storyman-circle:focus-visible .storyman-ring::after {
	opacity: 1;
	animation: storyman-ring-spin 3s linear infinite;
}

@keyframes storyman-ring-spin {
	to {
		transform: rotate( 360deg );
	}
}

.storyman-circle.is-seen .storyman-ring {
	background: var( --storyman-seen-ring-color, #c7c7c7 );
}

.storyman-avatar {
	width: 100%;
	height: 100%;
	border-radius: 50%;
	overflow: hidden;
	background: #f0f0f1;
	border: 2px solid #fff;
}

.storyman-avatar img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.storyman-title {
	font-size: 12px;
	line-height: 1.3;
	text-align: center;
	max-width: 84px;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	color: inherit;
}

@media ( max-width: 782px ) {
	.storyman-track {
		gap: 12px;
	}
}

.storyman-overlay {
	position: fixed;
	inset: 0;
	background: rgba( 0, 0, 0, 0.85 );
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
}

.storyman-popup {
	position: relative;
	width: var( --storyman-popup-width, 400px );
	height: var( --storyman-popup-height, 720px );
	max-width: 95vw;
	max-height: 92vh;
	background: #000;
	border-radius: 10px;
	overflow: hidden;
}

.storyman-progress-row {
	position: absolute;
	top: 8px;
	inset-inline-start: 8px;
	inset-inline-end: 8px;
	display: flex;
	gap: 4px;
	z-index: 5;
}

.storyman-progress-track {
	flex: 1 1 0;
	height: 3px;
	background: rgba( 255, 255, 255, 0.35 );
	border-radius: 3px;
	overflow: hidden;
}

.storyman-progress-fill {
	height: 100%;
	width: 0%;
	background: #fff;
}

.storyman-popup-header {
	position: absolute;
	top: 18px;
	inset-inline-start: 12px;
	inset-inline-end: 12px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	z-index: 5;
	color: #fff;
	font-size: 14px;
}

.storyman-popup-close,
.storyman-nav-arrow,
.storyman-play-pause {
	-webkit-tap-highlight-color: transparent;
	-webkit-appearance: none;
	appearance: none;
}

.storyman-popup-close {
	background: none;
	border: 0;
	color: #fff;
	font-size: 22px;
	line-height: 1;
	cursor: pointer;
	padding: 4px;
}

.storyman-popup-media {
	width: 100%;
	height: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
}

.storyman-popup-media img,
.storyman-popup-media video {
	width: 100%;
	height: 100%;
	object-fit: contain;
	background: #000;
}

.storyman-popup-media iframe {
	width: 100%;
	height: 100%;
	border: 0;
	background: #000;
}

.storyman-media-link {
	position: absolute;
	inset: 0;
	z-index: 3;
	display: block;
}

.storyman-nav-arrow {
	position: absolute;
	top: 50%;
	transform: translateY( -50% );
	z-index: 6;
	background: rgba( 0, 0, 0, 0.35 );
	color: #fff;
	border: 0;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	cursor: pointer;
	font-size: 16px;
}

.storyman-nav-arrow.prev {
	left: 8px;
}

.storyman-nav-arrow.next {
	right: 8px;
}

.storyman-play-pause {
	position: absolute;
	bottom: 14px;
	left: 50%;
	transform: translateX( -50% );
	z-index: 6;
	background: rgba( 0, 0, 0, 0.35 );
	color: #fff;
	border: 0;
	width: 36px;
	height: 36px;
	border-radius: 50%;
	cursor: pointer;
}

.storyman-cta {
	position: absolute;
	bottom: 16px;
	inset-inline-start: 16px;
	inset-inline-end: 16px;
	z-index: 5;
	display: flex;
	justify-content: center;
}

.storyman-cta a {
	background: #fff;
	color: #000;
	text-decoration: none;
	padding: 10px 20px;
	border-radius: 24px;
	font-size: 14px;
	font-weight: 600;
}

.storyman-product-info {
	position: absolute;
	top: 60px;
	inset-inline-start: 12px;
	z-index: 5;
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 6px;
}

.storyman-badge {
	display: inline-block;
	font-size: 11px;
	font-weight: 700;
	padding: 3px 8px;
	border-radius: 4px;
	color: #fff;
}

.storyman-badge-new {
	background: #2ecc71;
}

.storyman-badge-discount {
	background: #e74c3c;
}

.storyman-price-tag {
	background: rgba( 0, 0, 0, 0.55 );
	color: #fff;
	border-radius: 6px;
	padding: 6px 10px;
	font-size: 13px;
	display: flex;
	gap: 8px;
	align-items: center;
}

.storyman-price-old {
	text-decoration: line-through;
	opacity: 0.7;
	font-size: 12px;
}

.storyman-price-new {
	font-weight: 700;
	color: #ffd166;
}

.storyman-sale-ends {
	background: rgba( 0, 0, 0, 0.55 );
	color: #fff;
	border-radius: 6px;
	padding: 4px 10px;
	font-size: 11px;
}

.storyman-short-description {
	background: rgba( 0, 0, 0, 0.55 );
	color: #fff;
	border-radius: 6px;
	padding: 6px 10px;
	font-size: 12px;
	line-height: 1.5;
	max-width: 260px;
}

.storyman-related-products {
	position: absolute;
	bottom: 0;
	inset-inline-start: 0;
	inset-inline-end: 0;
	z-index: 6;
	display: flex;
	gap: 8px;
	overflow-x: auto;
	padding: 10px;
	background: linear-gradient( to top, rgba( 0, 0, 0, 0.75 ), rgba( 0, 0, 0, 0 ) );
}

.storyman-related-card {
	flex: 0 0 auto;
	width: 96px;
	background: #fff;
	border-radius: 8px;
	overflow: hidden;
	text-decoration: none;
	color: #000;
	display: flex;
	flex-direction: column;
}

.storyman-related-image {
	display: block;
	width: 100%;
	height: 72px;
	background: #f0f0f1;
}

.storyman-related-image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.storyman-related-title {
	font-size: 10px;
	line-height: 1.3;
	padding: 4px 6px 0;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.storyman-related-price {
	font-size: 10px;
	padding: 2px 6px 6px;
	display: flex;
	gap: 4px;
	align-items: center;
}

.storyman-avatar img {
	transition: opacity 0.25s ease;
}

.storyman-avatar.is-loading,
.storyman-popup-media.is-loading {
	background: linear-gradient( 90deg, #e6e6e8 25%, #f4f4f5 37%, #e6e6e8 63% );
	background-size: 400% 100%;
	animation: storyman-shimmer 1.4s ease infinite;
}

.storyman-popup-media.is-loading {
	background-image: linear-gradient( 90deg, #161616 25%, #2a2a2a 37%, #161616 63% );
}

.storyman-avatar.is-loading img,
.storyman-popup-media.is-loading > * {
	opacity: 0;
}

@keyframes storyman-shimmer {
	0% {
		background-position: 100% 0;
	}

	100% {
		background-position: 0 0;
	}
}

@property --storyman-angle {
	syntax: "<angle>";
	inherits: false;
	initial-value: 0deg;
}

.storyman-highlights {
	--storyman-shape-radius: 50%;
	--storyman-shape-clip: none;
}

.storyman-shape-square {
	--storyman-shape-radius: 22%;
}

.storyman-shape-hexagon {
	--storyman-shape-radius: 0;
	--storyman-shape-clip: polygon( 50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25% );
}

.storyman-fx .storyman-circle {
	--storyman-fx-accent: var( --storyman-ring-accent, #d62976 );
}

.storyman-fx .storyman-ring,
.storyman-fx .storyman-circle.is-seen .storyman-ring {
	background: none;
	border-radius: var( --storyman-shape-radius );
}

.storyman-fx .storyman-ring::before {
	content: "";
	position: absolute;
	inset: 0;
	border-radius: var( --storyman-shape-radius );
	clip-path: var( --storyman-shape-clip );
	background: var( --storyman-ring-color, #e1306c );
}

.storyman-fx .storyman-circle.is-seen .storyman-ring::before {
	background: var( --storyman-seen-ring-color, #c7c7c7 );
}

.storyman-fx .storyman-avatar {
	position: relative;
	z-index: 1;
	border-radius: var( --storyman-shape-radius );
	clip-path: var( --storyman-shape-clip );
}

.storyman-shape-square .storyman-ring::after,
.storyman-shape-hexagon .storyman-ring::after {
	border-radius: 0;
	-webkit-mask-composite: source-over;
	mask-composite: add;
}

.storyman-shape-square .storyman-ring::after {
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Crect x='1.5' y='1.5' width='97' height='97' rx='21' fill='none' stroke='black' stroke-width='3' pathLength='96' stroke-dasharray='4 2'/%3E%3C/svg%3E") center / 100% 100% no-repeat;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Crect x='1.5' y='1.5' width='97' height='97' rx='21' fill='none' stroke='black' stroke-width='3' pathLength='96' stroke-dasharray='4 2'/%3E%3C/svg%3E") center / 100% 100% no-repeat;
}

.storyman-shape-hexagon .storyman-ring::after {
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Cpolygon points='50,1.5 98.5,25.75 98.5,74.25 50,98.5 1.5,74.25 1.5,25.75' fill='none' stroke='black' stroke-width='3' stroke-linejoin='round' pathLength='96' stroke-dasharray='4 2'/%3E%3C/svg%3E") center / 100% 100% no-repeat;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Cpolygon points='50,1.5 98.5,25.75 98.5,74.25 50,98.5 1.5,74.25 1.5,25.75' fill='none' stroke='black' stroke-width='3' stroke-linejoin='round' pathLength='96' stroke-dasharray='4 2'/%3E%3C/svg%3E") center / 100% 100% no-repeat;
}

@keyframes storyman-ring-dash-pulse {

	0%,
	100% {
		transform: scale( 1 );
	}

	50% {
		transform: scale( 1.06 );
	}
}

@media ( hover: hover ) {
	.storyman-shape-square .storyman-circle:hover .storyman-ring::after,
	.storyman-shape-hexagon .storyman-circle:hover .storyman-ring::after {
		animation: storyman-ring-dash-pulse 1.4s ease-in-out infinite;
	}
}

.storyman-shape-square .storyman-circle:focus-visible .storyman-ring::after,
.storyman-shape-hexagon .storyman-circle:focus-visible .storyman-ring::after {
	animation: storyman-ring-dash-pulse 1.4s ease-in-out infinite;
}

.storyman-fx .storyman-circle.is-close-friends:not( .is-seen ) .storyman-ring::before {
	background: var( --storyman-cf-color, #22c55e );
}

.storyman-fx .storyman-circle.is-featured:not( .is-seen ) {
	--storyman-fx-accent: var( --storyman-featured-accent, #ee2a7b );
}

.storyman-fx .storyman-circle.is-featured:not( .is-seen ) .storyman-ring::before {
	background: var( --storyman-featured-color, linear-gradient( 45deg, #f9ce34, #ee2a7b ) );
}

.storyman-flag {
	position: absolute;
	bottom: -3px;
	inset-inline-end: -3px;
	z-index: 2;
	width: 22px;
	height: 22px;
	border: 2px solid #fff;
	border-radius: 50%;
	color: #fff;
	font-size: 11px;
	line-height: 18px;
	text-align: center;
}

.storyman-flag-featured {
	background: var( --storyman-featured-accent, #ee2a7b );
}

.storyman-flag-cf {
	background: var( --storyman-cf-color, #22c55e );
}

.storyman-circle.is-seen .storyman-flag {
	background: var( --storyman-seen-ring-color, #c7c7c7 );
}

.storyman-ring-anim-spin .storyman-circle:not( .is-seen ):not( .is-featured ):not( .is-close-friends ) .storyman-ring::before {
	background: conic-gradient( from var( --storyman-angle ), var( --storyman-ring-stops ) );
	animation: storyman-angle 3s linear infinite;
}

.storyman-ring-anim-flow .storyman-circle:not( .is-seen ):not( .is-featured ):not( .is-close-friends ) .storyman-ring::before {
	background: var( --storyman-ring-flow );
	background-size: 300% 100%;
	animation: storyman-flow 4s ease infinite;
}

.storyman-ring-anim-pulse .storyman-circle:not( .is-seen ):not( .is-featured ):not( .is-close-friends ) .storyman-ring,
.storyman-featured-pulse .storyman-circle.is-featured:not( .is-seen ) .storyman-ring {
	animation: storyman-pulse 1.8s ease-out infinite;
}

.storyman-ring-anim-glow .storyman-circle:not( .is-seen ):not( .is-featured ):not( .is-close-friends ) .storyman-ring,
.storyman-featured-glow .storyman-circle.is-featured:not( .is-seen ) .storyman-ring {
	animation: storyman-glow 2.2s ease-in-out infinite;
}

.storyman-ring-anim-breathe .storyman-circle:not( .is-seen ):not( .is-featured ):not( .is-close-friends ) .storyman-ring {
	animation: storyman-breathe 2.4s ease-in-out infinite;
}

.storyman-featured-spin .storyman-circle.is-featured:not( .is-seen ) .storyman-ring::before {
	background: conic-gradient( from var( --storyman-angle ), var( --storyman-featured-stops ) );
	animation: storyman-angle 2.4s linear infinite;
}

.storyman-featured-rainbow .storyman-circle.is-featured:not( .is-seen ) .storyman-ring::before {
	animation: storyman-hue 3s linear infinite;
}

@keyframes storyman-angle {
	to {
		--storyman-angle: 360deg;
	}
}

@keyframes storyman-flow {
	0%,
	100% {
		background-position: 0% 50%;
	}

	50% {
		background-position: 100% 50%;
	}
}

@keyframes storyman-pulse {
	0% {
		transform: scale( 1 );
		filter: drop-shadow( 0 0 0 transparent );
	}

	40% {
		transform: scale( 1.05 );
		filter: drop-shadow( 0 0 9px var( --storyman-fx-accent ) );
	}

	100% {
		transform: scale( 1 );
		filter: drop-shadow( 0 0 0 transparent );
	}
}

@keyframes storyman-glow {
	0%,
	100% {
		filter: drop-shadow( 0 0 3px var( --storyman-fx-accent ) );
	}

	50% {
		filter: drop-shadow( 0 0 10px var( --storyman-fx-accent ) );
	}
}

@keyframes storyman-breathe {
	0%,
	100% {
		transform: scale( 1 );
	}

	50% {
		transform: scale( 1.06 );
	}
}

@keyframes storyman-hue {
	to {
		filter: hue-rotate( 360deg );
	}
}

.storyman-overlay {
	perspective: 1400px;
	overscroll-behavior: contain;
}

.storyman-popup-actions {
	display: flex;
	align-items: center;
	gap: 4px;
}

.storyman-popup-media,
.storyman-media-link {
	touch-action: none;
	-webkit-user-select: none;
	user-select: none;
	-webkit-touch-callout: none;
}

.storyman-caption {
	position: absolute;
	inset-inline: 16px;
	bottom: 72px;
	z-index: 5;
	max-height: 34%;
	overflow: hidden;
	padding: 10px 14px;
	border-radius: 10px;
	background: rgba( 0, 0, 0, 0.5 );
	color: #fff;
	font-size: 14px;
	line-height: 1.6;
	text-align: center;
	white-space: pre-line;
	overflow-wrap: anywhere;
	pointer-events: none;
}

.storyman-popup.has-related .storyman-caption {
	bottom: 148px;
}

.storyman-popup-media[data-anim="fade"] > * {
	animation: storyman-media-fade 0.5s ease both;
}

.storyman-popup-media[data-anim="slide-up"] > * {
	animation: storyman-media-slide-up 0.5s ease both;
}

.storyman-popup-media[data-anim="zoom"] img {
	animation: storyman-media-zoom var( --storyman-slide-seconds, 5s ) linear both;
}

@keyframes storyman-media-fade {
	from {
		opacity: 0;
	}

	to {
		opacity: 1;
	}
}

@keyframes storyman-media-slide-up {
	from {
		opacity: 0;
		transform: translateY( 28px );
	}

	to {
		opacity: 1;
		transform: translateY( 0 );
	}
}

@keyframes storyman-media-zoom {
	from {
		transform: scale( 1 );
	}

	to {
		transform: scale( 1.12 );
	}
}

.storyman-popup {
	transform-origin: var( --storyman-origin, 50% ) 50%;
}

.storyman-popup.is-tr-fade {
	animation: storyman-tr-fade 0.35s ease both;
}

.storyman-popup.is-tr-slide {
	animation: storyman-tr-slide 0.4s ease both;
}

.storyman-popup.is-tr-flip {
	transform-origin: 50% 50%;
	animation: storyman-tr-flip 0.5s ease both;
}

.storyman-popup.is-tr-cube {
	animation: storyman-tr-cube 0.5s ease both;
}

@keyframes storyman-tr-fade {
	from {
		opacity: 0;
	}

	to {
		opacity: 1;
	}
}

@keyframes storyman-tr-slide {
	from {
		opacity: 0;
		transform: translateX( calc( var( --storyman-dir, 1 ) * 60px ) );
	}

	to {
		opacity: 1;
		transform: translateX( 0 );
	}
}

@keyframes storyman-tr-flip {
	from {
		opacity: 0.2;
		transform: rotateY( calc( var( --storyman-dir, 1 ) * -90deg ) );
	}

	to {
		opacity: 1;
		transform: rotateY( 0 );
	}
}

@keyframes storyman-tr-cube {
	from {
		opacity: 0.4;
		transform: translateX( calc( var( --storyman-dir, 1 ) * 40% ) ) rotateY( calc( var( --storyman-dir, 1 ) * 70deg ) );
	}

	to {
		opacity: 1;
		transform: translateX( 0 ) rotateY( 0 );
	}
}

@media ( max-width: 782px ) {
	.storyman-overlay {
		align-items: stretch;
		justify-content: stretch;
		background: #000;
	}

	.storyman-popup {
		width: 100%;
		height: 100%;
		max-width: none;
		max-height: none;
		border-radius: 0;
	}

	.storyman-progress-row {
		top: calc( 8px + env( safe-area-inset-top, 0px ) );
	}

	.storyman-popup-header {
		top: calc( 18px + env( safe-area-inset-top, 0px ) );
	}

	.storyman-popup-close {
		min-width: 44px;
		min-height: 44px;
		font-size: 30px;
	}

	.storyman-cta {
		bottom: calc( 16px + env( safe-area-inset-bottom, 0px ) );
	}

	.storyman-caption {
		bottom: calc( 72px + env( safe-area-inset-bottom, 0px ) );
	}
}

@supports ( height: 100dvh ) {
	@media ( max-width: 782px ) {
		.storyman-popup {
			height: 100dvh;
		}
	}
}

@media ( pointer: coarse ) {
	.storyman-nav-arrow {
		display: none;
	}
}

@media ( prefers-reduced-motion: reduce ) {
	.storyman-respect-motion.storyman-fx .storyman-ring,
	.storyman-respect-motion.storyman-fx .storyman-ring::before,
	.storyman-respect-motion .storyman-ring::after {
		animation: none !important;
	}

	.storyman-respect-motion .storyman-popup,
	.storyman-respect-motion .storyman-popup-media > * {
		animation: none !important;
	}
}
