/**
 * Product card — Figma 205:902
 * Variants: --default (PLP), --compact (bestsellers), --simple (newest/BOJ), --sale (akcija)
 */

.product-card {
	display: flex;
	flex-direction: column;
	box-sizing: border-box;
	width: 100%;
	height: 100%;
	min-width: 0;
	background: var(--surface-white);
	color: var(--ink-900);
	transition: box-shadow 0.2s ease;
}

.product-card:hover {
	box-shadow: var(--elevation-hover);
}

.product-card--default {
	gap: 12px;
	padding: 16px;
	border: 1px solid var(--border-subtle);
	border-radius: var(--radius-4);
}

.product-card--compact {
	padding: 16px;
	border-radius: 4px;
	overflow: hidden;
}

.product-card--simple,
.product-card--sale {
	gap: 12px;
	padding: 16px;
	border-radius: 4px;
	overflow: hidden;
	box-shadow: 0 0 3px rgba(0, 0, 0, 0.2);
}

.product-card__media {
	position: relative;
	display: block;
	width: 100%;
	aspect-ratio: 1 / 1;
	overflow: hidden;
	background: var(--surface-soft);
	border-radius: var(--radius-4);
}

.product-card--compact .product-card__media {
	margin-bottom: 12px;
	border-radius: 0;
	background: var(--surface-white);
}

.product-card--simple .product-card__media,
.product-card--sale .product-card__media {
	border-radius: 0;
}

.product-card__img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	object-position: center;
}

.product-card__img--empty {
	display: block;
	background: var(--color-surface-soft);
}

.product-card__star--empty {
	opacity: 0.22;
	filter: grayscale(1);
}

.product-card__star--half {
	opacity: 0.65;
}

.product-card__badge {
	position: absolute;
	top: 12px;
	left: 12px;
	padding: 4px 12px;
	border-radius: 999px;
	background: var(--accent-sale);
	color: var(--surface-white);
	font-size: 13px;
	font-weight: 700;
	line-height: 20px;
}

.product-card--sale .product-card__badge {
	top: 8px;
	left: auto;
	right: 8px;
	padding: 4px 10px;
}

.product-card__brand {
	margin: 0 0 4px;
	font-size: 13px;
	font-weight: 700;
	line-height: 20px;
}

.product-card--compact .product-card__brand {
	margin-bottom: 4px;
}

.product-card__title {
	margin: 0;
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
	overflow: hidden;
	font-size: 15px;
	font-weight: 400;
	line-height: 24px;
}

.product-card--default .product-card__title,
.product-card--simple .product-card__title,
.product-card--sale .product-card__title {
	min-height: 48px;
}

.product-card__title a:hover {
	text-decoration: underline;
}

.product-card__rating {
	display: flex;
	align-items: center;
	gap: 2px;
	margin: 4px 0 8px;
}

.product-card--compact .product-card__rating {
	margin: 8px 0;
}

.product-card__rating img {
	width: 16px;
	height: 16px;
	flex-shrink: 0;
}

.product-card__reviews {
	margin-left: 4px;
	font-size: 13px;
	line-height: 20px;
	color: var(--color-ink-500);
}

.product-card__prices {
	display: flex;
	flex-direction: column;
	gap: 2px;
	margin-top: auto;
	min-height: 64px;
}

.product-card__price {
	margin: 0;
	font-size: 20px;
	font-weight: 700;
	line-height: 26px;
}

.product-card__price--sale,
.product-card__price .woocommerce-Price-amount {
	color: inherit;
}

.product-card--default .product-card__price--sale,
.product-card--sale .product-card__price--sale {
	color: var(--ink-900);
}

.product-card__price del,
.product-card__price-old {
	margin: 0;
	font-size: 13px;
	font-weight: 400;
	line-height: 20px;
	color: var(--color-ink-500);
	text-decoration: line-through;
}

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

.product-card__save {
	margin: 0;
	font-size: 11px;
	font-weight: 700;
	line-height: 14px;
	letter-spacing: 0.8px;
	text-transform: uppercase;
	color: var(--ink-900);
}

.product-card__more {
	display: block;
	margin-top: 12px;
	font-size: 11px;
	font-weight: 500;
	line-height: 16px;
	color: var(--color-accent-info);
}

.product-card__more:hover {
	text-decoration: underline;
}

.product-card__actions {
	display: flex;
	align-items: center;
	gap: 8px;
	width: 100%;
	min-width: 0;
	margin-top: 8px;
}

.product-card__cta {
	display: inline-flex;
	flex: 1 1 auto;
	align-items: center;
	justify-content: center;
	min-width: 0;
	width: 100%;
	height: 40px;
	padding: 0 12px;
	border-radius: 8px;
	background: var(--color-neutral-900);
	color: var(--color-neutral-0);
	font-size: 11px;
	font-weight: 700;
	line-height: 14px;
	letter-spacing: 0.8px;
	text-transform: uppercase;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.product-card__cta:hover {
	background: var(--ink-700);
}

.product-card .added_to_cart,
a.added_to_cart {
	display: none;
}

.product-card-grid {
	display: grid;
	align-items: stretch;
	gap: 12px;
	list-style: none;
	margin: 0;
	padding: 0;
}

.product-card-grid--6 {
	grid-template-columns: repeat(6, minmax(0, 1fr));
}

.product-card-grid--5 {
	grid-template-columns: repeat(5, minmax(0, 1fr));
	gap: 20px;
}

.product-card-grid--4 {
	grid-template-columns: repeat(4, minmax(0, 1fr));
}

.product-card-grid > li,
.product-card-grid__item {
	display: flex;
	flex-direction: column;
	min-width: 0;
	list-style: none;
	margin: 0;
}

@media (max-width: 1199px) {
	.product-card-grid--4,
	.product-card-grid--5,
	.product-card-grid--6 {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

@media (max-width: 767px) {
	.product-card-grid--4,
	.product-card-grid--5,
	.product-card-grid--6 {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: var(--grid-gap);
	}
}

.product-card__cta--notify {
	background: transparent;
	color: var(--ink-900);
	border: 1px solid var(--ink-900);
}

.product-card__cta--notify:hover {
	background: var(--ink-900);
	color: var(--surface-white);
}

.product-card__badge--oos {
	background: var(--ink-700);
}

.products .cwginstock-subscribe-form,
.product-card .cwginstock-subscribe-form,
.cwg_popup_submit {
	display: none !important;
}
