/* =========================================================================
 * B10 — HERO HARMONIKA (accordion slider) — inspirirano ck-ribnjak hero sliderom.
 * Desktop/tablet (>=768): horizontalna harmonika (flex-grow) — hover/klik širi
 * karticu, ostale se skupe u trake s okomitim naslovom.
 * Mobitel (<=767): vertikalna harmonika (stack) — aktivna kartica se otvori.
 * Brand zelena #316747.
 * ========================================================================= */

.blato-b10-wrap { width: 100%; }

.blato-b10-hero {
	position: relative;
	width: 100%;
	overflow: hidden;
	background: #14281c;
}

.blato-b10-track {
	display: -webkit-box;
	display: -ms-flexbox;
	display: flex;
	width: 100%;
	height: var(--b10-height, 80vh);
	min-height: 340px;
	overflow: hidden;
}

.blato-b10-slide {
	position: relative;
	-webkit-box-flex: 1;
	-ms-flex: 1 1 0%;
	flex: 1 1 0%;
	min-width: 0;
	overflow: hidden;
	cursor: pointer;
	-webkit-transition: -webkit-box-flex .55s cubic-bezier(.65, 0, .35, 1);
	transition: flex-grow .55s cubic-bezier(.65, 0, .35, 1);
}
.blato-b10-slide.is-active {
	-webkit-box-flex: 5;
	-ms-flex-positive: 5;
	flex-grow: 5;
	cursor: default;
}

.blato-b10-bg {
	position: absolute;
	inset: 0;
	background-size: cover;
	background-position: center;
	transform: scale(1.03);
	transition: transform 6s ease;
}
.blato-b10-slide.is-active .blato-b10-bg { transform: scale(1.09); }

/* Overlay: sklopljene tamnije (brand tint), aktivna svjetlija + gradijent za tekst */
.blato-b10-overlay {
	position: absolute;
	inset: 0;
	background: rgba(15, 33, 23, .60);                                             /* fallback (bez color-mix) */
	background: color-mix(in srgb, var(--b10-overlay, #0f2117) calc(var(--b10-ov-strength, .62) * 100%), transparent);  /* boja slajda; jačina globalno preko --b10-ov-strength */
	transition: background .5s ease;
}
/* tamni gradijent na dnu aktivne kartice — čitljiv tekst bez obzira na boju */
.blato-b10-overlay::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(0deg, rgba(0, 0, 0, .68) 0%, rgba(0, 0, 0, 0) 52%);
	opacity: 0;
	transition: opacity .5s ease;
}
.blato-b10-slide.is-active .blato-b10-overlay {
	background: rgba(15, 33, 23, .26);
	background: color-mix(in srgb, var(--b10-overlay, #0f2117) calc(var(--b10-ov-strength, .62) * 35%), transparent);
}
/* Hover na OTVORENOM (aktivnom) slajdu: overlay se dodatno smanji — zasebno
   podesiva jačina preko postavke „Jačina overlaya na hoveru" (--b10-ov-hover). */
.blato-b10-slide.is-active:hover .blato-b10-overlay {
	background: rgba(15, 33, 23, .12);
	background: color-mix(in srgb, var(--b10-overlay, #0f2117) calc(var(--b10-ov-hover, .10) * 100%), transparent);
}
.blato-b10-slide.is-active .blato-b10-overlay::after { opacity: 1; }
.blato-b10-slide:not(.is-active):hover .blato-b10-overlay {
	background: rgba(15, 33, 23, .46);
	background: color-mix(in srgb, var(--b10-overlay, #0f2117) calc(var(--b10-ov-strength, .62) * 77%), transparent);
}

/* Okomiti naslov na sklopljenoj kartici (desktop) */
.blato-b10-label {
	position: absolute;
	inset: 0;
	z-index: 2;
	display: flex;
	align-items: flex-end;
	justify-content: flex-start;
	padding: 26px 0 26px 22px;
	pointer-events: none;
	opacity: 1;
	transition: opacity .3s ease;
}
.blato-b10-label > span {
	writing-mode: vertical-rl;
	transform: rotate(180deg);
	color: #fff;
	font-weight: 700;
	font-size: clamp(22px, 2.4vw, 38px);
	letter-spacing: .04em;
	text-transform: uppercase;
	white-space: nowrap;
	max-height: 88%;
	overflow: hidden;
	text-overflow: ellipsis;
	text-shadow: 0 1px 8px rgba(0, 0, 0, .55);
}
.blato-b10-slide.is-active .blato-b10-label { opacity: 0; }

/* Sadržaj aktivne kartice */
.blato-b10-content {
	position: absolute;
	left: 0;
	right: 0;
	bottom: clamp(28px, 4vw, 64px);
	z-index: 3;
	padding: 0 clamp(22px, 4vw, 64px);
	color: #fff;
	opacity: 0;
	transform: translateY(16px);
	transition: opacity .45s ease .12s, transform .45s ease .12s;
	pointer-events: none;
}
.blato-b10-slide.is-active .blato-b10-content {
	opacity: 1;
	transform: none;
	pointer-events: auto;
}

.blato-b10-title {
	margin: 0 0 10px;
	color: #fff;
	font-weight: 700;
	font-size: clamp(24px, 3vw, 48px);
	line-height: 1.1;
	letter-spacing: -.01em;
	text-shadow: 0 2px 14px rgba(0, 0, 0, .45);
	max-width: 760px;
}
.blato-b10-subtitle {
	margin: 0 0 18px;
	font-size: clamp(14px, 1.25vw, 19px);
	line-height: 1.45;
	max-width: 620px;
	text-shadow: 0 1px 10px rgba(0, 0, 0, .4);
}
.blato-b10-cta {
	display: -webkit-inline-box;
	display: -ms-inline-flexbox;
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 11px 22px;
	background: #316747;
	color: #fff !important;
	border-radius: 4px;
	font-weight: 700;
	font-size: 14px;
	text-decoration: none;
	transition: background .2s ease, transform .2s ease;
}
.blato-b10-cta:hover,
.blato-b10-cta:focus {
	background: #274f37;
	color: #fff !important;
	text-decoration: none;
	transform: translateY(-1px);
}
.blato-b10-cta__arrow { transition: transform .2s ease; }
.blato-b10-cta:hover .blato-b10-cta__arrow { transform: translateX(3px); }

/* Strelice (vidljive na hover hero-a) */
.blato-b10-nav {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 5;
	width: 46px;
	height: 46px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(0, 0, 0, .35);
	color: #fff;
	border: 0;
	border-radius: 50%;
	cursor: pointer;
	font-size: 22px;
	opacity: 0;
	transition: opacity .3s ease, background .2s ease;
}
.blato-b10-hero:hover .blato-b10-nav { opacity: 1; }
.blato-b10-nav:hover,
.blato-b10-nav:focus { background: #316747; outline: none; }
.blato-b10-prev { left: 16px; }
.blato-b10-next { right: 16px; }

/* Točkice (skrivene na desktopu, prikazane na mobitelu) */
.blato-b10-dots {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 14px;
	display: none;
	justify-content: center;
	gap: 8px;
	z-index: 5;
}
.blato-b10-dot {
	width: 9px;
	height: 9px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, .5);
	cursor: pointer;
	transition: background .2s ease, transform .2s ease;
}
.blato-b10-dot.is-active {
	background: #fff;
	transform: scale(1.25);
}

/* ---------- TABLET 768–1023 ---------- */
@media (min-width: 768px) and (max-width: 1023px) {
	.blato-b10-track { height: var(--b10-height, 80vh); }
	.blato-b10-slide.is-active {
		-webkit-box-flex: 4;
		-ms-flex-positive: 4;
		flex-grow: 4;
	}
}

/* ---------- MOBITEL <=767: vertikalna harmonika ---------- */
@media (max-width: 767px) {
	/* Fiksni header (position:fixed) prekriva vrh slidera -> spusti ga za
	   visinu headera. Fiksno 90px na svim mobilnim širinama. */
	.blato-b10-wrap {
		margin-top: 90px;
	}
	.blato-b10-track {
		-webkit-box-orient: vertical;
		-webkit-box-direction: normal;
		-ms-flex-direction: column;
		flex-direction: column;
		height: auto;
	}
	.blato-b10-slide {
		width: 100%;
		height: 70px;
		-webkit-box-flex: 0;
		-ms-flex: 0 0 auto;
		flex: 0 0 auto;
		transition: height .5s cubic-bezier(.65, 0, .35, 1);
	}
	.blato-b10-slide.is-active {
		height: var(--b10-height-mobile, 60vh);
	}
	.blato-b10-overlay {
		background: rgba(15, 33, 23, .55);
		background: color-mix(in srgb, var(--b10-overlay, #0f2117) calc(var(--b10-ov-strength, .62) * 89%), transparent);
	}
	.blato-b10-slide.is-active .blato-b10-overlay {
		background: rgba(15, 33, 23, .30);
		background: color-mix(in srgb, var(--b10-overlay, #0f2117) calc(var(--b10-ov-strength, .62) * 42%), transparent);
	}
	.blato-b10-label {
		padding: 0 18px;
		align-items: center;
		justify-content: flex-start;
	}
	.blato-b10-label > span {
		writing-mode: horizontal-tb;
		transform: none;
		max-height: none;
		font-size: 19px;
		font-weight: 700;
	}
	.blato-b10-content {
		bottom: 40px;
		padding: 0 18px;
	}
	.blato-b10-title { font-size: 26px !important; line-height: 1.15; }
	.blato-b10-subtitle { font-size: 14px; margin-bottom: 14px; }
	.blato-b10-cta { padding: 10px 18px; min-height: 44px; box-sizing: border-box; }
	.blato-b10-nav { display: none; }
	.blato-b10-dots { display: none; }
}

@media (prefers-reduced-motion: reduce) {
	.blato-b10-slide,
	.blato-b10-bg,
	.blato-b10-content,
	.blato-b10-overlay { transition: none !important; }
	.blato-b10-slide.is-active .blato-b10-bg { transform: none; }
}
