/**
 * Content Carousel Block Styles
 */

.content-carousel {
	margin: 4rem 0;
}

.carousel-container {
	position: relative;
}

/* Header */
.carousel-header {
	margin-bottom: 1.5rem;
}

.carousel-label {
	/* Inherits from .kodansha--smallcaps */
}

.carousel-title {
	/* Inherits from .kodansha--header--title */
}

/* Swiper Carousel */
.content-carousel__swiper {
	position: relative;
	overflow: hidden;
	margin: 0 -24px;
	padding: 0 24px;
}

@media (min-width: 768px) {
	.content-carousel__swiper {
		overflow: hidden;
		margin: 0;
		padding: 0;
	}
}

/* ~4 visible */
.content-carousel--count-4 .swiper-slide {
	width: 180px;
	height: auto;
}

@media (min-width: 768px) {
	.content-carousel--count-4 .swiper-slide {
		width: 220px;
	}
}

@media (min-width: 1024px) {
	.content-carousel--count-4 .swiper-slide {
		width: 260px;
	}
}

/* ~5 visible */
.content-carousel--count-5 .swiper-slide {
	width: 160px;
	height: auto;
}

@media (min-width: 768px) {
	.content-carousel--count-5 .swiper-slide {
		width: 180px;
	}
}

@media (min-width: 1024px) {
	.content-carousel--count-5 .swiper-slide {
		width: 200px;
	}
}

/* ~6 visible */
.content-carousel--count-6 .swiper-slide {
	width: 140px;
	height: auto;
}

@media (min-width: 768px) {
	.content-carousel--count-6 .swiper-slide {
		width: 160px;
	}
}

@media (min-width: 1024px) {
	.content-carousel--count-6 .swiper-slide {
		width: 170px;
	}
}

/* Carousel Item */
.carousel-item {
	width: 100%;
}

.carousel-item__link {
	display: block;
	text-decoration: none;
	color: inherit;
}

/* Image */
.carousel-item__image {
	position: relative;
	width: 100%;
	aspect-ratio: 2 / 3;
	border-radius: 0;
	overflow: hidden;
	margin-bottom: 0.75rem;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.carousel-item__image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.carousel-item__placeholder {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	background: var(--color-gray-mid);
	color: var(--color-gray-dark);
	font-size: 0.875rem;
}

/* Type Badge — inherits from .kd-badge */

/* Content */
.carousel-item__content {
	padding: 0;
}

.carousel-item__title {
	font-size: 0.875rem;
	font-family: "Maax Medium";
	font-weight: 400;
	line-height: 1.4;
	margin: 0 0 0.5rem 0;
	color: var(--color-black);
	overflow: hidden;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	min-height: 2.45em;
}

.carousel-item__title a {
	color: inherit;
	text-decoration: none;
}

.carousel-item__cta {
	display: inline-block;
	font-size: 0.6875rem;
	font-family: "Maax Bold";
	font-weight: 400;
	text-transform: uppercase;
	letter-spacing: 0.1em;
	color: var(--color-black);
	text-decoration: none;
	padding: 0;
	transition: opacity 0.2s ease;
	border-bottom: 1px solid var(--color-black);
}

/* Alignment Support */
.content-carousel.alignwide {
	max-width: var(--wp--custom--wide-size, 1280px);
	margin-left: auto;
	margin-right: auto;
}

.content-carousel.alignfull {
	max-width: 100%;
	padding-left: 1rem;
	padding-right: 1rem;
}

@media (min-width: 768px) {
	.content-carousel.alignfull {
		padding-left: 2rem;
		padding-right: 2rem;
	}
}


/* ==========================================================================
   Product Image Style Modifier
   ========================================================================== */

.content-carousel--img-product .swiper-wrapper {
	align-items: stretch !important;
}

/* Product image style in row items: match Coming Soon card look */
.content-carousel--img-product .carousel-item-row__image {
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 0.625rem;
	box-sizing: border-box;
}

.content-carousel--img-product .carousel-item-row__image img {
	width: auto;
	height: auto;
	max-width: 100%;
	max-height: 100%;
	object-fit: contain;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

/* ==========================================================================
   Grid Card Count Modifier
   ========================================================================== */

.content-carousel--count-grid .content-carousel__swiper {
	margin: 0;
	padding: 0;
}

.content-carousel--count-grid .swiper-slide {
	width: 100%;
	height: auto;
}

/* Footer — View More button (uses .arrow-container base) */
.content-carousel__footer {
	display: flex;
	justify-content: flex-end;
	margin-top: 1.5rem;
}
