/*
 * Wspólne karty produktów.
 *
 * Ten sam komponent jest używany na stronie głównej, w katalogu i w sekcji
 * "Podobne produkty". Dzięki temu wygląd jest spójny, a CSS nie jest duplikowany.
 */

.product-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 26px 20px;
	margin: 0;
	padding: 0;
	list-style: none;
}

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

.product-landing__title {
	margin: 30px 0;
	font-size: 48px;
	line-height: 1.2;
	text-align: center;
	text-transform: uppercase;
}

.product-landing .product-grid {
	margin-top: 30px;
}

.product-card {
	position: relative;
	min-width: 0;
	margin: 0;
	padding: 0;
	text-align: center;
	list-style: none;
}

.product-card__media {
	position: relative;
	display: block;
	width: 100%;
	overflow: hidden;
}

.product-card__image {
	width: 100%;
	height: auto;
	aspect-ratio: 1 / 1;
	object-fit: contain;
	transition: transform 0.25s ease;
}

.product-card:hover .product-card__image {
	transform: scale(1.025);
}

.product-card__badge {
	position: absolute;
	top: 2px;
	right: 2px;
	z-index: 2;
	padding: 5px 7px;
	border-radius: 2px;
	background: var(--color-sale);
	color: #fff;
	font-family: var(--font-body);
	font-size: 14.56px;
	font-weight: 600;
	line-height: 1;
	text-transform: uppercase;
}

.product-card__title {
	margin: 12px 0 0;
	font-family: var(--font-heading);
	font-size: 19.2px;
	font-weight: 700;
	line-height: 1.4;
	text-transform: none;
}

.product-card__title a {
	display: inline-block;
	color: inherit;
	text-decoration: none;
}

/* Strony "Dla niej / Dla niego / Dla dziecka" — bardziej zwarta siatka,
   czarne pogrubione nazwy i biały, pogrubiony przycisk z delikatnym zoomem. */
.product-landing .product-grid {
	max-width: 1100px;
	margin-inline: auto;
}

.product-landing .product-card__title {
	font-size: 21px;
	font-weight: 700;
	color: #000;
}

.product-landing .product-card__title a {
	color: #000;
	text-decoration: none;
}

.product-landing .product-card__button {
	color: #fff;
	font-weight: 700;
	background: var(--color-primary);
	text-decoration: none;
	transition: transform 0.2s ease, background-color 0.2s ease;
}

.product-landing .product-card__button:link,
.product-landing .product-card__button:visited,
.product-landing .product-card__button:hover,
.product-landing .product-card__button:focus,
.product-landing .product-card__button:focus-visible,
.product-landing .product-card__button:active {
	color: #fff;
	text-decoration: none;
}

.product-landing .product-card__button:hover,
.product-landing .product-card__button:focus-visible {
	background: var(--color-primary);
	color: #fff;
	transform: scale(1.04);
}

/* Paginacja również na stronach landingowych (poza archive-product.php). */
.woocommerce-pagination {
	margin-top: 32px;
	text-align: center;
}

.woocommerce-pagination ul {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	margin: 0;
	padding: 0;
	border: 0;
	list-style: none;
}

.woocommerce-pagination li {
	margin: 0;
	list-style: none;
}

.woocommerce-pagination a,
.woocommerce-pagination span {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 30px;
	height: 30px;
	padding: 0 6px;
	border-radius: 3px;
	font-size: 16px;
}

.woocommerce-pagination span.current,
.woocommerce-pagination a:hover {
	background: var(--color-primary);
	color: #fff;
}

.product-card__price {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: center;
	gap: 8px;
	margin-top: 6px;
	font-family: var(--font-body);
	font-size: 20.8px;
	font-weight: 700;
	line-height: 1.5;
	color: var(--color-primary);
}

.product-card__price del {
	color: #6d7175;
	font-size: 16px;
	font-weight: 400;
	text-decoration: line-through;
}

.product-card__price ins {
	color: var(--color-primary);
	font-weight: 700;
	text-decoration: none;
}

.product-card__button {
	margin-top: 10px;
}

/* Karuzela nowości — przewijanie poziome z przyciskami. */
.product-carousel {
	position: relative;
	margin-top: 24px;
}

.product-carousel__controls {
	position: absolute;
	top: -46px;
	right: 0;
	display: flex;
	gap: 16px;
	z-index: 2;
}

.product-carousel__arrow {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	padding: 0;
	border: 0;
	background: transparent;
	color: #9aa0a6;
}

.product-carousel__arrow:hover,
.product-carousel__arrow:focus-visible {
	color: var(--color-text);
}

.product-carousel__track {
	display: flex;
	gap: 25.6px;
	margin: 0;
	padding: 4px;
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	scrollbar-width: none;
	list-style: none;
}

.product-carousel__track::-webkit-scrollbar {
	display: none;
}

.product-carousel__track > .product-card {
	flex: 0 0 246px;
	scroll-snap-align: start;
}

.product-carousel .product-card__price {
	font-size: 22.4px;
	font-weight: 400;
}

.product-carousel .product-card__price ins {
	font-weight: 400;
}
