/**
 * Divi Section Scroll — front-end styles.
 *
 * Dot navigation, tooltips and the scroll-down arrow. Colours, sizes and
 * z-index arrive as CSS variables printed inline by the plugin.
 */

/* The engine animates window.scrollTo itself, so CSS smooth scrolling
   (set by Divi or other plugins) must not double-animate the jumps. */
html.dss-enabled {
	scroll-behavior: auto !important;
}

/* Sections receive focus after keyboard/dot navigation for accessibility —
   hide the resulting outline on the section container itself. */
html.dss-enabled [data-dss-target]:focus {
	outline: none;
}

/* ── Dot navigation ─────────────────────────────────────────────── */
.dss-nav {
	position: fixed;
	top: 50%;
	transform: translateY(-50%);
	z-index: var(--dss-z, 9999);
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 14px;
	margin: 0;
	padding: 6px;
}
.dss-nav--right {
	right: 22px;
}
.dss-nav--left {
	left: 22px;
}

.dss-nav button {
	-webkit-appearance: none;
	appearance: none;
	display: block;
	position: relative;
	width: var(--dss-dot-size, 12px);
	height: var(--dss-dot-size, 12px);
	padding: 0;
	margin: 0;
	border: 0;
	border-radius: 50%;
	background: var(--dss-dot-color, #b9c2cf);
	box-shadow: none;
	cursor: pointer;
	transition: transform 0.2s ease, background-color 0.2s ease, width 0.2s ease;
}
.dss-nav button:hover {
	transform: scale(1.25);
}
.dss-nav button.is-active {
	background: var(--dss-dot-active, #2f80ed);
	transform: scale(1.35);
}
.dss-nav button:focus-visible {
	outline: 2px solid var(--dss-dot-active, #2f80ed);
	outline-offset: 3px;
}

/* Squares */
.dss-style-squares button {
	border-radius: 3px;
}

/* Lines */
.dss-style-lines button {
	width: calc(var(--dss-dot-size, 12px) * 2);
	height: 4px;
	border-radius: 2px;
}
.dss-style-lines button:hover {
	transform: none;
	width: calc(var(--dss-dot-size, 12px) * 2.6);
}
.dss-style-lines button.is-active {
	transform: none;
	width: calc(var(--dss-dot-size, 12px) * 3);
}

/* Tooltips */
.dss-nav[data-tooltips] button::after {
	content: attr(data-label);
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	white-space: nowrap;
	background: #1f2937;
	color: #fff;
	font-size: 12px;
	line-height: 1;
	padding: 6px 10px;
	border-radius: 6px;
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
	transition: opacity 0.15s ease, visibility 0.15s ease;
}
.dss-nav--right[data-tooltips] button::after {
	right: calc(100% + 12px);
}
.dss-nav--left[data-tooltips] button::after {
	left: calc(100% + 12px);
}
.dss-nav[data-tooltips] button:hover::after,
.dss-nav[data-tooltips] button:focus-visible::after {
	opacity: 1;
	visibility: visible;
}

/* ── Scroll-down arrow ──────────────────────────────────────────── */
.dss-arrow {
	position: fixed;
	left: 50%;
	bottom: 26px;
	transform: translateX(-50%);
	z-index: var(--dss-z, 9999);
	display: flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 0;
	background: transparent;
	color: var(--dss-arrow, #ffffff);
	cursor: pointer;
	opacity: 0.85;
	animation: dss-bounce 2s ease-in-out infinite;
	transition: opacity 0.25s ease;
}
.dss-arrow svg {
	width: 32px;
	height: 32px;
	fill: none;
	stroke: currentColor;
	stroke-width: 2.4;
	stroke-linecap: round;
	stroke-linejoin: round;
	filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.35));
}
.dss-arrow:hover {
	opacity: 1;
}
.dss-arrow:focus-visible {
	outline: 2px solid currentColor;
	outline-offset: 2px;
	border-radius: 50%;
}
.dss-arrow.is-hidden {
	opacity: 0;
	pointer-events: none;
}

@keyframes dss-bounce {
	0%,
	20%,
	50%,
	80%,
	100% {
		transform: translate(-50%, 0);
	}
	40% {
		transform: translate(-50%, 8px);
	}
	60% {
		transform: translate(-50%, 4px);
	}
}

/* ── Accessibility & print ──────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
	.dss-nav button,
	.dss-nav[data-tooltips] button::after {
		transition: none;
	}
	.dss-arrow {
		animation: none;
	}
}

@media print {
	.dss-nav,
	.dss-arrow {
		display: none !important;
	}
}
