/* =========================================================
   Sticky Scroll Tabs — frontend styles
   Class prefix: .sst-
   ========================================================= */

.sst-widget * {
	box-sizing: border-box;
}

.sst-wrapper {
	display: flex;
	/* stretch so the left column matches the tall scroll track on the right;
	   this gives the left tabs the same sticky range, so BOTH panels pin. */
	align-items: stretch;
	gap: 32px;
	width: 100%;
}

/* Each column needs a positioning context taller than its sticky child. */
.sst-tabs-panel,
.sst-content-col {
	position: relative;
}

/* ----- Left: tabs ----- */
.sst-tabs-panel {
	flex: 0 0 32%;
	max-width: 32%;
	min-width: 0;
}

.sst-pinned {
	position: -webkit-sticky;
	position: sticky;
	top: 80px;
}

.sst-tabs-list {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: 8px;
	padding-left: 0;
	margin: 0;
	list-style: none;
}

.sst-tab {
	position: relative;
	display: flex;
	align-items: flex-start;
	gap: 10px;
	width: 100%;
	min-width: 0;
	text-align: left;
	cursor: pointer;
	border: 1px solid #ececf1;
	background: #fff;
	color: #5b5f6b;
	padding: 14px 16px;
	border-radius: 10px;
	font: inherit;
	line-height: 1.35;
	box-shadow: none;
	transition: background-color .2s ease, color .2s ease, box-shadow .2s ease;
	-webkit-appearance: none;
	appearance: none;
}

.sst-tab:focus-visible {
	outline: 2px solid #7c3aed;
	outline-offset: 2px;
}

.sst-tab-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	line-height: 1;
	margin-top: 1px;
}

.sst-tab-icon i {
	font-size: 18px;
}

.sst-tab-icon svg {
	width: 18px;
	height: 18px;
}

.sst-tab-img {
	width: 18px;
	height: 18px;
	object-fit: contain;
	display: block;
}

.sst-tab-title {
	display: block;
	flex: 1 1 auto;
	min-width: 0;
	white-space: normal;
	overflow-wrap: break-word;
	word-wrap: break-word;
	word-break: break-word;
	hyphens: auto;
}

/* ----- Right: content column ----- */
.sst-content-col {
	flex: 1 1 64%;
	min-width: 0;
}

.sst-content-panel {
	position: relative;
	background: #fff;
	border-radius: 14px;
	padding: 28px 32px;
	min-height: 0;
	height: auto;
	overflow: hidden;
}

/* Optional per-slide background image */
.sst-slide-bg {
	position: absolute;
	inset: 0;
	background-size: cover;
	background-position: center;
	opacity: .12;
	z-index: 0;
	pointer-events: none;
}

.sst-slide-content {
	position: relative;
	z-index: 1;
}

.sst-section-image {
	display: block;
	max-width: 100%;
	height: auto;
	margin-bottom: 18px;
	border-radius: 10px;
}

/* ----- WYSIWYG content typography defaults ----- */
.sst-wysiwyg {
	color: #4b4f5c;
	line-height: 1.65;
}

.sst-wysiwyg > *:first-child { margin-top: 0; }
.sst-wysiwyg > *:last-child  { margin-bottom: 0; }

.sst-wysiwyg h1, .sst-wysiwyg h2, .sst-wysiwyg h3,
.sst-wysiwyg h4, .sst-wysiwyg h5, .sst-wysiwyg h6 {
	color: #1f2330;
	margin: 0 0 .6em;
	line-height: 1.25;
}

.sst-wysiwyg p { margin: 0 0 1em; }

.sst-wysiwyg ul,
.sst-wysiwyg ol {
	margin: 0 0 1em;
	padding-left: 1.25em;
}

.sst-wysiwyg li { margin: 0 0 .4em; }

.sst-wysiwyg a {
	color: #7c3aed;
	text-decoration: none;
}
.sst-wysiwyg a:hover { text-decoration: underline; }

/* Media inside the WYSIWYG editor must never overflow the panel on phones */
.sst-wysiwyg img,
.sst-wysiwyg video,
.sst-wysiwyg iframe {
	max-width: 100%;
	height: auto;
}

.sst-wysiwyg table {
	max-width: 100%;
	display: block;
	overflow-x: auto;
}

/* ----- Progress line ----- */
.sst-progress-line {
	position: absolute;
	left: -14px;
	top: 6px;
	bottom: 6px;
	width: 3px;
	border-radius: 3px;
	background: rgba(124, 58, 237, .15);
	overflow: hidden;
}
.sst-progress-fill {
	position: absolute;
	left: 0;
	top: 0;
	width: 100%;
	height: 0%;
	background: #7c3aed;
	border-radius: 3px;
	transition: height .25s ease;
}

/* =========================================================
   STICKY MODE — pinned stage, stacked fading slides
   ========================================================= */
.sst-mode-sticky .sst-track {
	position: relative;
}

.sst-mode-sticky .sst-content-pinned {
	/* top is set inline by Elementor sticky_offset control */
}

.sst-mode-sticky .sst-content-panel {
	display: block; /* height follows the active section */
}

.sst-mode-sticky .sst-slide {
	display: none;
}

.sst-mode-sticky .sst-slide.is-active {
	display: block;
	animation: sstFadeIn var(--sst-fade, 400ms) ease;
}

/* Used briefly by JS to measure slide heights; never painted. */
.sst-mode-sticky .sst-slide.sst-measure {
	display: block !important;
	animation: none !important;
}

/* Opacity-only: a translate here shifts content down on every switch,
   which reads as extra space appearing above the content. */
@keyframes sstFadeIn {
	from { opacity: 0; }
	to   { opacity: 1; }
}

/* =========================================================
   STATIC MODE — sections flow normally, observer drives tabs
   ========================================================= */
.sst-mode-static .sst-sections {
	display: flex;
	flex-direction: column;
	gap: 24px;
}

.sst-mode-static .sst-section {
	transition: opacity .3s ease;
}

/* =========================================================
   RESPONSIVE — stack + horizontal tab scroller
   ========================================================= */
/* !important on the layout-critical props: Elementor's per-device CSS for
   the Left/Right Panel Width controls loads after this file and would
   otherwise keep the columns side-by-side on phones. */
.sst-widget.sst-is-mobile .sst-wrapper {
	flex-direction: column !important;
	gap: 16px;
}

.sst-widget.sst-is-mobile .sst-tabs-panel,
.sst-widget.sst-is-mobile .sst-content-col {
	flex: 1 1 100% !important;
	max-width: 100% !important;
	width: 100% !important;
}

.sst-widget.sst-is-mobile .sst-pinned {
	position: static !important;
	top: auto !important;
}

.sst-widget.sst-is-mobile .sst-tabs-list {
	flex-direction: row !important;
	overflow-x: auto;
	gap: 8px;
	padding-bottom: 6px;
	scrollbar-width: thin;
	-webkit-overflow-scrolling: touch;
	overscroll-behavior-x: contain;
	scroll-snap-type: x proximity;
}

.sst-widget.sst-is-mobile .sst-tab {
	flex: 0 0 auto;
	width: auto;
	white-space: normal;
	max-width: 70vw;
	scroll-snap-align: center;
	touch-action: manipulation;
}

/* Full title always visible: long titles wrap onto new lines below. */
.sst-widget.sst-is-mobile .sst-tab-title {
	white-space: normal;
	overflow: visible;
	text-overflow: clip;
	overflow-wrap: break-word;
	word-break: break-word;
}

.sst-widget.sst-is-mobile .sst-progress-line {
	display: none;
}

/* In mobile sticky mode the inner tracks collapse; the whole stacked wrapper
   pins instead (per-widget offset comes from the scoped inline style). */
.sst-widget.sst-is-mobile .sst-track {
	height: auto !important;
}
.sst-widget.sst-is-mobile.sst-mode-sticky .sst-wrapper {
	position: -webkit-sticky;
	position: sticky;
	top: 80px;
}
.sst-widget.sst-is-mobile.sst-mode-sticky .sst-content-panel {
	display: block;
}
.sst-widget.sst-is-mobile.sst-mode-sticky .sst-slide {
	position: static;
	opacity: 1;
	visibility: visible;
	transform: none;
	pointer-events: auto;
	display: none;
}
.sst-widget.sst-is-mobile.sst-mode-sticky .sst-slide.is-active {
	display: block;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
	.sst-slide,
	.sst-progress-fill,
	.sst-tab {
		transition: none !important;
		animation: none !important;
	}
}
