/* =========================================================================
   Gardenium - Carousel kategorija
   Stil widgeta. Boje su uskladjene sa Gardenium sajtom:
   #1BAE70 (primarna zelena), #06752E (tamna zelena), #14261C (tamni tekst),
   #4E5652 (priguseni tekst), #F4F6F4 (svetla pozadina).
   ========================================================================= */

.gcc-carousel {
	--gcc-green: #1BAE70;
	--gcc-green-dark: #06752E;
	--gcc-ink: #14261C;
	--gcc-muted: #4E5652;
	--gcc-soft: #F4F6F4;
	position: relative;
	width: 100%;
	font-family: 'Poppins', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
	box-sizing: border-box;
}

.gcc-carousel *,
.gcc-carousel *::before,
.gcc-carousel *::after {
	box-sizing: border-box;
}

/* --- Stage (drzi viewport + strelice) --------------------------------- */
.gcc-stage {
	position: relative;
}

/* --- Viewport / Track ------------------------------------------------- */
.gcc-viewport {
	overflow: hidden;
	width: 100%;
	touch-action: pan-y; /* Dozvoljava vertikalni skrol, horizontalni hvata carousel. */
}

.gcc-track {
	display: flex;
	align-items: stretch;
	will-change: transform;
	transition: transform 600ms cubic-bezier(0.22, 0.61, 0.36, 1);
}

.gcc-track.gcc-no-transition {
	transition: none !important;
}

.gcc-carousel.gcc-is-grabbing .gcc-track {
	cursor: grabbing;
}

.gcc-carousel.gcc-draggable .gcc-viewport {
	cursor: grab;
}

/* --- Slide ------------------------------------------------------------ */
.gcc-slide {
	flex: 0 0 auto;
	width: 280px; /* Pocetna vrednost; JS racuna tacnu sirinu. */
	display: flex;
	height: auto;
}

/* --- Kartica ---------------------------------------------------------- */
.gcc-card {
	position: relative;
	display: flex;
	flex-direction: column;
	width: 100%;
	text-decoration: none;
	background-color: #FFFFFF;
	border-radius: 16px;
	overflow: hidden;
	box-shadow: 0 6px 22px rgba(20, 38, 28, 0.08);
	transition: transform 320ms cubic-bezier(0.22, 0.61, 0.36, 1),
		box-shadow 320ms ease;
}

.gcc-card:hover {
	transform: translateY(-8px);
	box-shadow: 0 16px 34px rgba(20, 38, 28, 0.16);
}

.gcc-card:focus-visible {
	outline: 3px solid var(--gcc-green);
	outline-offset: 2px;
}

/* --- Slika kartice ---------------------------------------------------- */
.gcc-card-media {
	position: relative;
	width: 100%;
	height: 200px; /* Pregazi ga Elementor kontrola "Visina slike". */
	overflow: hidden;
	background-color: var(--gcc-soft);
}

.gcc-card-image {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform 600ms cubic-bezier(0.22, 0.61, 0.36, 1);
}

.gcc-card:hover .gcc-card-image {
	transform: scale(1.07);
}

/* Blagi preliv na dnu slike radi citljivosti i dubine. */
.gcc-card-media::after {
	content: "";
	position: absolute;
	inset: auto 0 0 0;
	height: 38%;
	background: linear-gradient(to top, rgba(20, 38, 28, 0.18), rgba(20, 38, 28, 0));
	pointer-events: none;
}

/* --- Telo kartice (tekst) -------------------------------------------- */
.gcc-card-body {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 9px;
	padding: 18px 18px 20px;
	flex: 1 1 auto;
}

.gcc-card-title {
	margin: 0;
	font-family: inherit;
	font-size: 17px;
	font-weight: 600;
	line-height: 1.35;
	color: var(--gcc-ink);
	transition: color 220ms ease;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.gcc-card:hover .gcc-card-title {
	color: var(--gcc-green);
}

.gcc-card-count {
	display: inline-flex;
	align-items: center;
	padding: 4px 11px;
	font-family: inherit;
	font-size: 12.5px;
	font-weight: 500;
	line-height: 1.6;
	letter-spacing: 0.2px;
	color: var(--gcc-green-dark);
	background-color: #EAF7F0;
	border-radius: 999px;
}

/* --- Strelice --------------------------------------------------------- */
.gcc-arrow {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 5;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 46px;
	height: 46px;
	padding: 0;
	margin: 0;
	border: none;
	border-radius: 50%;
	background-color: #FFFFFF;
	box-shadow: 0 6px 18px rgba(20, 38, 28, 0.18);
	cursor: pointer;
	transition: background-color 220ms ease, transform 220ms ease,
		opacity 220ms ease, box-shadow 220ms ease;
	-webkit-appearance: none;
	appearance: none;
}

.gcc-arrow svg {
	width: 56%;
	height: 56%;
	fill: var(--gcc-green-dark);
	transition: fill 220ms ease;
	pointer-events: none;
}

.gcc-arrow:hover {
	background-color: var(--gcc-green);
}

.gcc-arrow:hover svg {
	fill: #FFFFFF;
}

.gcc-arrow:active {
	transform: translateY(-50%) scale(0.94);
}

.gcc-arrow:focus-visible {
	outline: 3px solid var(--gcc-green);
	outline-offset: 2px;
}

.gcc-arrow-prev {
	left: -14px;
}

.gcc-arrow-next {
	right: -14px;
}

.gcc-arrow[disabled] {
	opacity: 0;
	pointer-events: none;
}

/* Kad nema dovoljno kartica, sakrij celu kontrolu. */
.gcc-carousel.gcc-static .gcc-arrow,
.gcc-carousel.gcc-static .gcc-dots {
	display: none;
}

.gcc-carousel.gcc-static .gcc-track {
	justify-content: center;
}

/* --- Tackice ---------------------------------------------------------- */
.gcc-dots {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 8px;
	margin-top: 22px;
}

.gcc-dot {
	width: 9px;
	height: 9px;
	padding: 0;
	border: none;
	border-radius: 50%;
	background-color: #CBE3D6;
	cursor: pointer;
	transition: background-color 220ms ease, width 260ms ease;
	-webkit-appearance: none;
	appearance: none;
}

.gcc-dot:hover {
	background-color: var(--gcc-green);
}

.gcc-dot.is-active {
	width: 26px;
	border-radius: 999px;
	background-color: var(--gcc-green);
}

.gcc-dot:focus-visible {
	outline: 2px solid var(--gcc-green);
	outline-offset: 2px;
}

/* --- Prazno stanje ---------------------------------------------------- */
.gcc-empty {
	padding: 28px 22px;
	text-align: center;
	font-family: 'Poppins', 'Inter', sans-serif;
	font-size: 15px;
	color: var(--gcc-muted, #4E5652);
	background-color: #F4F6F4;
	border-radius: 14px;
}

/* --- Pre nego sto se JS ucita ---------------------------------------- */
.gcc-carousel:not(.gcc-initialized) .gcc-track {
	gap: 24px;
}

.gcc-carousel:not(.gcc-initialized) .gcc-arrow {
	opacity: 0;
}

/* --- Manji ekrani ----------------------------------------------------- */
@media (max-width: 767px) {
	.gcc-arrow-prev {
		left: 4px;
	}
	.gcc-arrow-next {
		right: 4px;
	}
	.gcc-card-title {
		font-size: 16px;
	}
}

/* Postuje korisnike koji su iskljucili animacije. */
@media (prefers-reduced-motion: reduce) {
	.gcc-track,
	.gcc-card,
	.gcc-card-image {
		transition-duration: 1ms !important;
	}
}
