/**
 * Kase Category Slider - front-end stylesheet.
 *
 * All selectors are scoped under the `kcs-` prefix and nested inside
 * `.kcs-wrapper` so this file never collides with WoodMart theme styles.
 */

.kcs-wrapper {
	position: relative;
	box-sizing: border-box;
	width: 100%;
	margin: 24px 0;
}

.kcs-wrapper *,
.kcs-wrapper *::before,
.kcs-wrapper *::after {
	box-sizing: border-box;
}

.kcs-swiper {
	width: 100%;
	overflow: hidden;
	padding: 4px 2px 12px;
}

.kcs-swiper-wrapper {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
}

/* ---------- Slide ---------- */

.kcs-slide {
	list-style: none;
	height: auto;
	display: flex;
}

/* ---------- Card ---------- */

.kcs-card {
	display: flex;
	align-items: center;
	gap: 14px;
	width: 100%;
	height: 90px;
	padding: 0 18px;
	background-color: #ffffff;
	border: 1px solid #eef2f6;
	border-radius: 18px;
	text-decoration: none !important;
	color: inherit;
	transition: transform 300ms ease, box-shadow 300ms ease, border-color 300ms ease;
	will-change: transform;
}

.kcs-card:hover,
.kcs-card:focus-visible {
	transform: translateY(-4px);
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
	border-color: #eef2f6;
	text-decoration: none !important;
	color: inherit;
}

/* ---------- Left: image ---------- */

.kcs-card-image {
	flex: 0 0 56px;
	width: 56px;
	height: 56px;
	border-radius: 14px;
	overflow: hidden;
	background-color: #f5f7fa;
	display: block;
}

.kcs-card-image img {
	display: block;
	width: 100%;
	height: 100%;
	-o-object-fit: cover;
	object-fit: cover;
}

/* ---------- Middle: text ---------- */

.kcs-card-body {
	flex: 1 1 auto;
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 2px;
}

.kcs-card-title {
	font-size: 16px;
	font-weight: 600;
	line-height: 1.25;
	color: #16181b;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	text-overflow: ellipsis;
}

.kcs-card-count {
	font-size: 14px;
	font-weight: 400;
	line-height: 1.3;
	color: #808080;
}

/* ---------- Right: arrow ---------- */

.kcs-card-arrow {
	flex: 0 0 20px;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #b7bec7;
	transition: color 300ms ease, transform 300ms ease;
}

.kcs-card:hover .kcs-card-arrow,
.kcs-card:focus-visible .kcs-card-arrow {
	color: #2b6bfd;
	transform: translateX(2px);
}

/* ---------- Navigation arrows ---------- */

.kcs-nav {
	position: absolute;
	top: 45px;
	transform: translateY(-50%);
	z-index: 2;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	border-radius: 50%;
	border: 1px solid #eef2f6;
	background-color: #ffffff;
	color: #16181b;
	cursor: pointer;
	box-shadow: 0 6px 18px rgba(0, 0, 0, 0.06);
	transition: color 300ms ease, box-shadow 300ms ease, opacity 300ms ease;
	padding: 0;
}

.kcs-nav:hover {
	color: #2b6bfd;
	box-shadow: 0 8px 22px rgba(0, 0, 0, 0.1);
}

.kcs-nav-prev {
	left: -20px;
}

.kcs-nav-next {
	right: -20px;
}

.kcs-nav.swiper-button-disabled {
	opacity: 0.35;
	cursor: default;
	pointer-events: none;
}

.kcs-nav svg {
	display: block;
}

/* ---------- Responsive ---------- */

/* Mobile: 0 - 767px -> arrows hidden, ~1.2 cards visible (handled by Swiper JS breakpoints). */
@media (max-width: 767px) {
	.kcs-nav {
		display: none;
	}

	.kcs-card {
		height: 84px;
		padding: 0 14px;
		gap: 12px;
	}

	.kcs-card-title {
		font-size: 15px;
	}
}

/* Tablet: 768 - 1199px. */
@media (min-width: 768px) and (max-width: 1199px) {
	.kcs-nav-prev {
		left: -14px;
	}

	.kcs-nav-next {
		right: -14px;
	}
}
