/* Salmod stories */
.salmod-stories {
	--salmod-ring: var(--salmod-brand, #AF2464);
	margin: 12px 0 20px;
}
.salmod-stories__heading {
	font-size: 1.05rem;
	margin: 0 0 10px;
}
.salmod-stories__track {
	display: flex;
	gap: 14px;
	overflow-x: auto;
	overscroll-behavior-x: contain;
	scroll-snap-type: x proximity;
	scrollbar-width: none;
	padding: 4px 2px 6px;
	-webkit-overflow-scrolling: touch;
}
.salmod-stories__track::-webkit-scrollbar { display: none; }
.salmod-stories__item { flex: 0 0 auto; scroll-snap-align: start; }

.salmod-story {
	all: unset;
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 6px;
	width: 80px;
	cursor: pointer;
	text-align: center;
	-webkit-tap-highlight-color: transparent;
}
.salmod-story:focus-visible .salmod-story__ring { outline: 2px solid var(--salmod-ring); outline-offset: 3px; }
.salmod-story__ring {
	display: block;
	width: 76px;
	height: 76px;
	border-radius: 50%;
	padding: 3px;
	background: conic-gradient(from 210deg, var(--salmod-ring), var(--salmod-brand-on-dark, #F3B8CE), var(--salmod-ring));
	transition: transform .2s ease;
}
.salmod-story:hover .salmod-story__ring { transform: scale(1.04); }
.salmod-story.is-seen .salmod-story__ring { background: #d4d4d4; }
.salmod-story.is-seen .salmod-story__title { color: var(--salmod-muted-fg, #57534E); }
.salmod-story__ring img {
	display: block;
	width: 100%;
	height: 100%;
	border-radius: 50%;
	object-fit: cover;
	border: 3px solid #fff;
	background: #f3f3f3;
	box-sizing: border-box;
}
.salmod-story__title {
	font-size: 12px;
	line-height: 1.4;
	max-width: 80px;
	overflow: hidden;
	white-space: nowrap;
	text-overflow: ellipsis;
	color: inherit;
}
@media (max-width: 600px) {
	.salmod-story { width: 68px; }
	.salmod-story__ring { width: 66px; height: 66px; }
	.salmod-story__title { max-width: 68px; font-size: 11px; }
}

/* Viewer */
html.salmod-sv-lock, html.salmod-sv-lock body { overflow: hidden !important; }
.salmod-sv {
	position: fixed;
	inset: 0;
	z-index: 999999;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 16px;
	background: rgba(10, 10, 10, .94);
	direction: ltr;
}
.salmod-sv[hidden], .salmod-sv [hidden] { display: none !important; }
.salmod-sv__frame {
	position: relative;
	width: 100vw;
	height: 100vh;
	height: 100dvh;
	background: #000;
	overflow: hidden;
	touch-action: none;
	user-select: none;
	-webkit-user-select: none;
}
@media (min-width: 601px) {
	.salmod-sv__frame { border-radius: 14px; height: min(92dvh, calc(460px * 16 / 9)); width: min(460px, calc(92dvh * 9 / 16)); }
}
.salmod-sv__media, .salmod-sv__media img, .salmod-sv__media video {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: contain;
	-webkit-user-drag: none;
}
.salmod-sv__bars {
	position: absolute;
	top: 10px;
	left: 10px;
	right: 10px;
	display: flex;
	gap: 4px;
	z-index: 3;
}
.salmod-sv__bar { flex: 1; height: 3px; border-radius: 3px; background: rgba(255,255,255,.35); overflow: hidden; }
.salmod-sv__fill { display: block; height: 100%; width: 0; background: #fff; }
.salmod-sv__head {
	position: absolute;
	top: 20px;
	left: 10px;
	right: 10px;
	display: flex;
	align-items: center;
	gap: 8px;
	z-index: 3;
	color: #fff;
	direction: rtl;
	text-shadow: 0 1px 3px rgba(0,0,0,.5);
}
.salmod-sv__avatar { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; border: 1px solid rgba(255,255,255,.6); }
.salmod-sv__title { flex: 1; font-size: 14px; font-weight: 600; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.salmod-sv__btn {
	all: unset;
	cursor: pointer;
	width: 44px;
	height: 44px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	touch-action: manipulation;
	font-size: 26px;
	line-height: 1;
	color: #fff;
}
.salmod-sv__btn svg { filter: drop-shadow(0 1px 2px rgba(0,0,0,.5)); }
.salmod-sv__btn:focus-visible, .salmod-sv__nav:focus-visible, .salmod-sv__cta:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.salmod-sv__spinner {
	position: absolute;
	top: 50%;
	left: 50%;
	width: 34px;
	height: 34px;
	margin: -17px 0 0 -17px;
	border: 3px solid rgba(255,255,255,.25);
	border-top-color: #fff;
	border-radius: 50%;
	animation: salmod-spin .8s linear infinite;
	z-index: 2;
}
.salmod-sv__spinner[hidden] { display: none; }
@keyframes salmod-spin { to { transform: rotate(360deg); } }
.salmod-sv__cta {
	position: absolute;
	bottom: 24px;
	left: 50%;
	transform: translateX(-50%);
	z-index: 3;
	padding: 12px 26px;
	border-radius: 999px;
	background: #fff;
	color: #111 !important;
	font-weight: 700;
	font-size: 14px;
	text-decoration: none !important;
	white-space: nowrap;
	box-shadow: 0 6px 20px rgba(0,0,0,.25);
	direction: rtl;
}
.salmod-sv__cta[hidden] { display: none; }
.salmod-sv.is-paused .salmod-sv__bars, .salmod-sv.is-paused .salmod-sv__head, .salmod-sv.is-paused .salmod-sv__cta { opacity: 0; transition: opacity .2s .25s; }
.salmod-sv__nav {
	all: unset;
	cursor: pointer;
	width: 44px;
	height: 44px;
	border-radius: 50%;
	background: rgba(255,255,255,.9);
	display: none;
	align-items: center;
	justify-content: center;
}
.salmod-sv__nav::before {
	content: "";
	width: 10px;
	height: 10px;
	border-top: 2px solid #111;
	border-right: 2px solid #111;
	transform: rotate(45deg);
	margin-left: -4px;
}
.salmod-sv__nav--prev::before { transform: rotate(-135deg); margin-left: 4px; }
@media (min-width: 768px) {
	.salmod-sv__nav { display: inline-flex; }
}
@media (prefers-reduced-motion: reduce) {
	.salmod-story__ring, .salmod-sv__spinner { transition: none; animation-duration: 2s; }
}
