/**
 * Tempest Product Slider & Carousel for WooCommerce
 * Author: Tempest Technologies
 */

.tempest-ps {
	position: relative;
	box-sizing: border-box;
	margin: 0 0 2em;
	padding: 0 40px;
}

.tempest-ps *,
.tempest-ps *::before,
.tempest-ps *::after {
	box-sizing: border-box;
}

.tempest-ps__viewport {
	overflow: hidden;
	width: 100%;
}

.tempest-ps__track {
	display: flex;
	flex-wrap: nowrap;
	transition: transform 600ms cubic-bezier(0.25, 0.1, 0.25, 1);
	will-change: transform;
}

.tempest-ps__slide {
	flex: 0 0 auto;
	min-width: 0;
	padding: 0 8px;
}

.tempest-ps__card {
	display: flex;
	flex-direction: column;
	height: 100%;
	background: #fff;
	border: 1px solid #eee;
	border-radius: 6px;
	overflow: hidden;
	transition: box-shadow 200ms ease, transform 200ms ease;
}

.tempest-ps__card:hover {
	box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
	transform: translateY(-2px);
}

.tempest-ps__image {
	position: relative;
	display: block;
	overflow: hidden;
	background: #f7f7f7;
}

.tempest-ps__image img {
	display: block;
	width: 100%;
	height: auto;
	transition: transform 300ms ease;
}

.tempest-ps__card:hover .tempest-ps__image img {
	transform: scale(1.03);
}

.tempest-ps__badge {
	position: absolute;
	top: 10px;
	left: 10px;
	padding: 3px 8px;
	font-size: 11px;
	font-weight: 600;
	line-height: 1;
	color: #fff;
	border-radius: 3px;
	text-transform: uppercase;
	letter-spacing: 0.04em;
}

.tempest-ps__badge--sale {
	background: #e2401c;
}

.tempest-ps__badge--oos {
	top: auto;
	left: 10px;
	bottom: 10px;
	background: #333;
}

.tempest-ps__body {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	padding: 12px 14px 16px;
	gap: 6px;
}

.tempest-ps__title {
	font-size: 15px;
	line-height: 1.3;
	margin: 0;
	font-weight: 600;
	text-align: center;
	width: 100%;
}

.tempest-ps__title a {
	color: inherit;
	text-decoration: none;
}

.tempest-ps__title a:hover {
	text-decoration: underline;
}

.tempest-ps__rating {
	font-size: 13px;
}

.tempest-ps__rating .star-rating {
	margin: 0;
}

.tempest-ps__price {
	font-size: 15px;
	font-weight: 600;
}

.tempest-ps__price del {
	opacity: 0.55;
	font-weight: 400;
	margin-right: 4px;
}

.tempest-ps__price ins {
	background: none;
	text-decoration: none;
}

.tempest-ps__cart {
	margin-top: 8px;
}

.tempest-ps__add-to-cart {
	display: inline-block;
}

/* Arrows */
.tempest-ps__arrow {
	position: absolute;
	top: 50%;
	z-index: 2;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	padding: 0;
	margin: 0;
	border: 1px solid #ddd;
	background: #fff;
	color: #333;
	font-size: 18px;
	line-height: 1;
	border-radius: 50%;
	cursor: pointer;
	transform: translateY(-50%);
	transition: background 150ms ease, color 150ms ease, border-color 150ms ease, opacity 150ms ease;
}

.tempest-ps__arrow:hover:not(:disabled) {
	background: #111;
	color: #fff;
	border-color: #111;
}

.tempest-ps__arrow:disabled {
	opacity: 0.35;
	cursor: default;
}

.tempest-ps__arrow--prev {
	left: 0;
}

.tempest-ps__arrow--next {
	right: 0;
}

/* Dots */
.tempest-ps__dots {
	display: flex;
	justify-content: center;
	gap: 6px;
	margin-top: 14px;
}

.tempest-ps__dots button {
	width: 10px;
	height: 10px;
	padding: 0;
	border: none;
	border-radius: 50%;
	background: #ccc;
	cursor: pointer;
	transition: background 150ms ease, transform 150ms ease;
}

.tempest-ps__dots button.is-active {
	background: #111;
	transform: scale(1.15);
}

/* Responsive breakpoints handled via JS (data-config) — these are fallbacks */
@media (max-width: 1024px) {
	.tempest-ps {
		padding: 0 32px;
	}
}

@media (max-width: 640px) {
	.tempest-ps {
		padding: 0 28px;
	}

	.tempest-ps__title {
		font-size: 14px;
	}
}
