/* ===================== ZAJEDNIČKO ===================== */

.aspp-r {
	width: 100%;
}

.aspp-notice {
	padding: 12px 16px;
	border: 1px dashed #c3c4c7;
	border-radius: 4px;
	background: #f6f7f7;
	color: #50575e;
	font-size: 13px;
}

.aspp-empty {
	font-size: 0.95em;
}

/* ===================== GRID ===================== */

.aspp-r-grid {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	column-gap: 20px;
	row-gap: 30px;
}

@media (max-width: 1024px) {
	.aspp-r-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 767px) {
	.aspp-r-grid {
		grid-template-columns: repeat(1, minmax(0, 1fr));
	}
}

/* ===================== KARTICA ===================== */

.aspp-card {
	position: relative;
	display: flex;
	flex-direction: column;
	height: 100%;
	min-width: 0;
	transition-property: background-color, border-color, box-shadow, transform;
	transition-timing-function: ease;
	transition-duration: 0.3s;
}

/* Nevidljivi link preko cele kartice; dugme u korpu je iznad njega. */
.aspp-card__overlay {
	position: absolute;
	inset: 0;
	z-index: 1;
	font-size: 0;
	text-indent: -9999px;
}

.aspp-card__media {
	position: relative;
	overflow: hidden;
	margin-bottom: 14px;
	line-height: 0;
}

.aspp-card__media img,
.aspp-card__img {
	display: block;
	width: 100%;
	height: auto;
	transition: transform 0.4s ease, opacity 0.3s ease;
}

.aspp-card--hover-zoom:hover .aspp-card__media img {
	transform: scale(1.06);
}

.aspp-card--hover-fade:hover .aspp-card__media img {
	opacity: 0.75;
}

.aspp-card__sale {
	position: absolute;
	top: 10px;
	left: 10px;
	z-index: 2;
	display: inline-block;
	padding: 3px 10px;
	border-radius: 3px;
	background: #e53935;
	color: #fff;
	font-size: 12px;
	line-height: 1.6;
	text-transform: uppercase;
	letter-spacing: 0.03em;
}

.aspp-card__body {
	position: relative;
	display: flex;
	flex-direction: column;
	flex: 1 1 auto;
	min-width: 0;
}

.aspp-card__badge {
	display: inline-block;
	max-width: 100%;
	margin-bottom: 6px;
	font-size: 13px;
	line-height: 1.4;
	align-self: inherit;
}

/* Kad je ACF tekst preko slike. */
.aspp-card__media .aspp-card__badge {
	position: absolute;
	right: 10px;
	bottom: 10px;
	z-index: 2;
	margin: 0;
	padding: 4px 10px;
	border-radius: 3px;
	background: rgba(0, 0, 0, 0.7);
	color: #fff;
}

.aspp-card__title {
	margin: 0 0 8px;
	font-size: 1rem;
	line-height: 1.35;
	word-break: break-word;
}

.aspp-card__title a {
	color: inherit;
	text-decoration: none;
}

.aspp-card__rating {
	margin-bottom: 6px;
	line-height: 1;
}

.aspp-card__rating .star-rating {
	display: inline-block;
	float: none;
	margin: 0;
}

.aspp-card__price {
	margin: 0 0 10px;
	line-height: 1.4;
}

.aspp-card__price del {
	opacity: 0.6;
	margin-right: 6px;
}

.aspp-card__price ins {
	text-decoration: none;
}

.aspp-card__excerpt {
	margin: 0 0 12px;
	font-size: 0.9em;
	line-height: 1.5;
}

.aspp-card__cart {
	position: relative;
	z-index: 2;
	padding-top: 4px;
}

/* Kad je dugme poslednji element, gura se na dno radi jednakih visina kartica. */
.aspp-card__cart--push {
	margin-top: auto;
}

.aspp-card__cart .button {
	display: inline-block;
	cursor: pointer;
	transition: background-color 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

.aspp-card__cart .added_to_cart {
	display: inline-block;
	margin-top: 6px;
	font-size: 0.85em;
}

/* ===================== SLIDER ===================== */

.aspp-r-slider {
	position: relative;
}

.aspp-slider__viewport {
	overflow: hidden;
	width: 100%;
}

.aspp-slider__track {
	display: flex;
	column-gap: 20px;
	will-change: transform;
}

.aspp-slider__slide {
	flex: 0 0 auto;
	min-width: 0;
	box-sizing: border-box;
}

.aspp-slider--dragging .aspp-slider__track {
	cursor: grabbing;
	transition: none !important;
}

.aspp-slider--dragging .aspp-card__overlay {
	pointer-events: none;
}

.aspp-slider__arrow {
	position: absolute;
	top: 50%;
	z-index: 5;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 1px solid rgba(0, 0, 0, 0.1);
	border-radius: 50%;
	background: #fff;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
	cursor: pointer;
	transform: translateY(-50%);
	transition: background-color 0.25s ease, border-color 0.25s ease, opacity 0.25s ease;
}

.aspp-slider__arrow--prev {
	left: 0;
}

.aspp-slider__arrow--next {
	right: 0;
}

.aspp-slider__arrow svg {
	width: 16px;
	height: 16px;
	fill: #222;
	pointer-events: none;
	transition: fill 0.25s ease;
}

.aspp-slider__arrow[disabled] {
	opacity: 0.35;
	cursor: default;
	pointer-events: none;
}

.aspp-slider__arrow.is-hidden {
	display: none;
}

.aspp-slider__dots {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	margin-top: 20px;
}

.aspp-slider__dots.is-hidden {
	display: none;
}

.aspp-slider__dot {
	width: 10px;
	height: 10px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: #ccc;
	cursor: pointer;
	transition: background-color 0.25s ease, transform 0.25s ease;
}

.aspp-slider__dot.is-active {
	background: #222;
	transform: scale(1.15);
}
