/**
 * Avalehe slaider.
 *
 * Values here mirror the Elementor hero it replaces, breakpoint for
 * breakpoint: the navy overlay gradient, the 1280px content column, the
 * clamp()ed heading, and the mobile reorder that puts the button above the
 * body text. See inc/hero-slider.php.
 */

.allika-hero {
	position: relative;
	overflow: hidden;
	padding: 0 48px 1px;
	background: #0c283a;
}

.allika-hero-viewport {
	position: relative;
}

.allika-hero-slide {
	min-height: 740px;
	background-position: center center;
	background-repeat: no-repeat;
	background-size: cover;
}

/* Every slide after the first stacks on top, hidden, ready to cross-fade */
.allika-hero.has-multiple .allika-hero-slide {
	position: absolute;
	inset: 0;
	opacity: 0;
	visibility: hidden;
	transition: opacity .6s ease, visibility .6s;
}

.allika-hero.has-multiple .allika-hero-slide:first-child {
	position: relative;
}

.allika-hero.has-multiple .allika-hero-slide.is-active {
	opacity: 1;
	visibility: visible;
}

/* Dark wash so the white text stays readable over any photo */
.allika-hero-slide::before {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, rgba(12, 40, 58, .78), rgba(12, 40, 58, .45));
	pointer-events: none;
}

.allika-hero-inner {
	position: relative;
	z-index: 1;
	display: flex;
	width: 100%;
	max-width: 1280px;
	margin: 0 auto;
	padding: 140px 0 100px;
}

.allika-hero-content {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 24px;
	width: min(760px, 78%);
	flex: 0 0 auto;
}

.allika-hero-title {
	margin: 0;
	font-family: "Poppins", sans-serif;
	font-size: clamp(42px, 3.4vw, 54px);
	font-weight: 700;
	line-height: 1.16;
	letter-spacing: -.8px;
	color: #fff;
}

.allika-hero-text,
.allika-hero-text p {
	margin: 0;
	font-family: "Inter", sans-serif;
	font-size: 17px;
	font-weight: 400;
	line-height: 1.8;
	color: #fff;
	max-width: 740px;
	text-wrap: pretty;
}

.allika-hero-text p + p {
	margin-top: 1em;
}

.allika-hero-actions {
	margin-top: 6px;
}

.allika-hero-button {
	display: inline-block;
	padding: 18px 32px;
	border-radius: 10px;
	background: #03b8e5;
	color: #fff;
	font-family: "Poppins", sans-serif;
	font-size: 16px;
	font-weight: 600;
	line-height: 1.3;
	letter-spacing: 1px;
	text-transform: uppercase;
	text-decoration: none;
	transition: background-color .2s ease, transform .2s ease;
}

.allika-hero-button:hover,
.allika-hero-button:focus {
	background: #1a1a1a;
	color: #fff;
	text-decoration: none;
	transform: translateY(-2px);
}

.allika-hero-badge {
	display: block;
	width: 64px;
	height: auto;
	margin-top: 8px;
}

/* The white curve at the bottom edge */
.allika-hero-shape {
	position: absolute;
	bottom: -1px;
	left: 0;
	z-index: 2;
	width: 100%;
	overflow: hidden;
	line-height: 0;
	direction: ltr;
	pointer-events: none;
}

.allika-hero-shape svg {
	position: relative;
	left: 50%;
	display: block;
	width: calc(100% + 1.3px);
	height: 100px;
	transform: translateX(-50%);
}

.allika-hero-shape path {
	fill: #fff;
}

/* --- Controls ----------------------------------------------------------- */

.allika-hero-arrow {
	position: absolute;
	top: 50%;
	z-index: 3;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 48px;
	height: 48px;
	padding: 0;
	border: 1px solid rgba(255, 255, 255, .45);
	border-radius: 50%;
	background: rgba(12, 40, 58, .35);
	color: #fff;
	cursor: pointer;
	transform: translateY(-50%);
	transition: background-color .2s ease, border-color .2s ease;
}

.allika-hero-arrow:hover,
.allika-hero-arrow:focus-visible {
	background: #03b8e5;
	border-color: #03b8e5;
}

.allika-hero-arrow svg {
	width: 22px;
	height: 22px;
	fill: none;
	stroke: currentColor;
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.allika-hero-prev {
	left: 20px;
}

.allika-hero-next {
	right: 20px;
}

.allika-hero-dots {
	position: absolute;
	bottom: 116px;
	left: 50%;
	z-index: 3;
	display: flex;
	gap: 10px;
	transform: translateX(-50%);
}

.allika-hero-dot {
	width: 10px;
	height: 10px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, .45);
	cursor: pointer;
	transition: background-color .2s ease, width .2s ease;
}

.allika-hero-dot.is-active {
	width: 28px;
	border-radius: 999px;
	background: #03b8e5;
}

/* --- Tablet ------------------------------------------------------------- */

@media (max-width: 1024px) {
	.allika-hero {
		padding: 0 32px 1px;
	}

	.allika-hero-slide {
		min-height: 620px;
	}

	.allika-hero-inner {
		padding: 100px 0 90px;
	}

	.allika-hero-content {
		width: min(680px, 90%);
	}

	.allika-hero-title {
		font-size: clamp(34px, 4.4vw, 44px);
	}
}

/* --- Mobile ------------------------------------------------------------- */

@media (max-width: 767px) {
	.allika-hero {
		padding: 0;
	}

	.allika-hero-slide {
		min-height: 0;
		height: auto;
	}

	.allika-hero-inner {
		padding: 48px 24px 32px;
	}

	.allika-hero-content {
		width: 100%;
		gap: 18px;
	}

	.allika-hero-title {
		font-size: 34px;
		line-height: 1.12;
		letter-spacing: -.6px;
		overflow-wrap: anywhere;
	}

	.allika-hero-text,
	.allika-hero-text p {
		font-size: 16px;
		line-height: 1.6;
		color: #f0f6f9;
	}

	/* On phones the call to action sits above the paragraph */
	.allika-hero-title { order: 1; }
	.allika-hero-actions { order: 2; margin-top: 0; }
	.allika-hero-text { order: 3; }
	.allika-hero-badge { order: 4; }

	.allika-hero-actions {
		width: 100%;
	}

	.allika-hero-button {
		display: block;
		width: 100%;
		padding: 16px 24px;
		font-family: "Inter", sans-serif;
		font-size: 15px;
		letter-spacing: 0;
		text-align: center;
	}

	.allika-hero-badge {
		width: 42px;
	}

	/* The curve is hidden on phones, as it was in the Elementor version */
	.allika-hero-shape {
		display: none;
	}

	.allika-hero-arrow {
		width: 38px;
		height: 38px;
	}

	.allika-hero-prev { left: 8px; }
	.allika-hero-next { right: 8px; }

	.allika-hero-dots {
		bottom: 14px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.allika-hero.has-multiple .allika-hero-slide,
	.allika-hero-button,
	.allika-hero-dot {
		transition: none;
	}

	.allika-hero-button:hover,
	.allika-hero-button:focus {
		transform: none;
	}
}
