/* Book Showcase for Elementor — by Tarak Vora (https://www.tarakvora.in) */

.bs-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 30px;
	align-items: stretch;
}

/* ---------- Card ---------- */
.bs-card {
	--bs-accent: #1a5cff;
	--bs-btn-bg: var(--bs-accent);
	--bs-btn-hover: #0f3fbf;
	--bs-btn-color: #fff;
	--bs-tag-bg: #e5233b;
	--bs-tint: 10%;
	position: relative;
	display: flex;
	flex-direction: column;
	background: #fff;
	border-radius: 24px;
	padding: 26px;
	box-shadow: 0 12px 40px rgba(20, 32, 63, 0.08);
	overflow: hidden;
	transition: transform 0.35s ease, box-shadow 0.35s ease;
}
.bs-lift-yes .bs-card:hover,
.bs-lift-yes .bs-card.is-hover {
	transform: translateY(-6px);
	box-shadow: 0 24px 56px rgba(20, 32, 63, 0.14);
}

/* ---------- Media / images ---------- */
.bs-media {
	position: relative;
	height: 340px;
	display: flex;
	align-items: flex-end;
	justify-content: center;
	margin-bottom: 20px;
	-webkit-tap-highlight-color: transparent;
}
.bs-media-bg {
	position: absolute;
	inset: 0;
	background: center bottom / contain no-repeat;
	pointer-events: none;
}
.bs-img {
	position: relative;
	z-index: 1;
	width: 68%;
	height: 92%;
	display: flex;
	align-items: flex-end;
	justify-content: center;
}
.bs-img a {
	display: contents;
}
.bs-img img {
	display: block;
	max-width: 100%;
	max-height: 100%;
	width: auto;
	height: auto;
	object-fit: contain;
	filter: drop-shadow(0 22px 28px rgba(20, 32, 63, 0.28));
	transition: opacity 0.45s ease, transform 0.55s cubic-bezier(0.22, 0.61, 0.36, 1);
	backface-visibility: hidden;
}
.bs-img .bs-img-2 {
	position: absolute;
	left: 50%;
	bottom: 0;
	transform: translateX(-50%);
	opacity: 0;
}

/* Fade (default) */
.bs-has-hover:hover .bs-img-1,
.bs-has-hover.is-hover .bs-img-1 { opacity: 0; }
.bs-has-hover:hover .bs-img-2,
.bs-has-hover.is-hover .bs-img-2 { opacity: 1; }

/* Fade + Zoom */
.bs-hover-zoom .bs-img-2 { transform: translateX(-50%) scale(0.92); }
.bs-hover-zoom .bs-has-hover:hover .bs-img-2,
.bs-hover-zoom .bs-has-hover.is-hover .bs-img-2 { transform: translateX(-50%) scale(1.04); }
.bs-hover-zoom .bs-has-hover:hover .bs-img-1,
.bs-hover-zoom .bs-has-hover.is-hover .bs-img-1 { transform: scale(1.06); }

/* Slide up */
.bs-hover-slide .bs-img-2 { transform: translateX(-50%) translateY(28px); }
.bs-hover-slide .bs-has-hover:hover .bs-img-2,
.bs-hover-slide .bs-has-hover.is-hover .bs-img-2 { transform: translateX(-50%) translateY(0); }
.bs-hover-slide .bs-has-hover:hover .bs-img-1,
.bs-hover-slide .bs-has-hover.is-hover .bs-img-1 { transform: translateY(-28px); }

/* Flip */
.bs-hover-flip .bs-img { perspective: 1200px; }
.bs-hover-flip .bs-img-2 { transform: translateX(-50%) rotateY(180deg); }
.bs-hover-flip .bs-has-hover:hover .bs-img-2,
.bs-hover-flip .bs-has-hover.is-hover .bs-img-2 { transform: translateX(-50%) rotateY(0deg); }
.bs-hover-flip .bs-has-hover:hover .bs-img-1,
.bs-hover-flip .bs-has-hover.is-hover .bs-img-1 { transform: rotateY(-180deg); }

/* ---------- Tag ---------- */
.bs-tag {
	position: absolute;
	top: 0;
	left: 0;
	z-index: 2;
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 10px 20px;
	background: var(--bs-tag-bg);
	color: #fff;
	font-size: 15px;
	font-weight: 700;
	line-height: 1;
	letter-spacing: 0.02em;
	border-radius: 999px;
	box-shadow: 0 6px 16px rgba(229, 35, 59, 0.28);
}
.bs-tag-icon {
	display: inline-flex;
	font-size: 0.95em;
}
.bs-tag-icon i,
.bs-tag-icon svg {
	width: 1em;
	height: 1em;
	fill: currentColor;
}


/* ---------- Body ---------- */
.bs-body {
	--bs-just: flex-start;
	display: flex;
	flex-direction: column;
	flex: 1;
}
.bs-title {
	margin: 0 0 4px;
	font-size: 25px;
	font-weight: 700;
	line-height: 1.25;
	color: #14203f;
}
.bs-title a {
	color: inherit;
	text-decoration: none;
}
.bs-title a:hover { color: var(--bs-accent); }
.bs-subtitle {
	margin: 0 0 16px;
	font-size: 19px;
	line-height: 1.4;
	color: #4b5675;
}

/* ---------- Price ---------- */
.bs-price-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	flex-wrap: wrap;
	margin-bottom: 18px;
}
.bs-price-row { justify-content: var(--bs-just-row, space-between); }
.bs-usps { justify-content: var(--bs-just-row, space-between); }
.bs-prices {
	display: flex;
	align-items: baseline;
	gap: 12px;
	flex-wrap: wrap;
}
.bs-price-regular {
	font-size: 19px;
	color: #8a93a6;
	text-decoration: line-through;
}
.bs-price-sale {
	font-size: 26px;
	font-weight: 800;
	line-height: 1;
	color: var(--bs-accent);
}
.bs-discount {
	display: inline-block;
	padding: 7px 14px;
	border-radius: 999px;
	font-size: 15px;
	font-weight: 700;
	line-height: 1.2;
	color: var(--bs-accent);
	background: color-mix(in srgb, var(--bs-accent) var(--bs-tint), #fff);
}
@supports not (color: color-mix(in srgb, red, blue)) {
	.bs-discount { background: #f0f3fa; }
}

/* ---------- USP ---------- */
.bs-usps {
	list-style: none;
	margin: 0 0 20px;
	padding: 16px 0 0;
	border-top: 1px solid #e9edf5;
	display: flex;
	justify-content: space-between;
	gap: 12px;
}
.bs-usp {
	display: flex;
	align-items: center;
	gap: 10px;
	flex: 1 1 0;
	min-width: 0;
}
.bs-usp-icon {
	flex: 0 0 auto;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 24px;
	font-size: 24px;
	color: var(--bs-accent);
}
.bs-usp-icon i { font-size: inherit; }
.bs-usp-icon svg {
	width: 1em;
	height: 1em;
	fill: currentColor;
}
.bs-usp-text {
	font-size: 14.5px;
	line-height: 1.3;
	color: #4b5675;
}

/* ---------- Button ---------- */
.bs-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 14px;
	width: 100%;
	margin-top: auto;
	padding: 16px 24px;
	border-radius: 16px;
	background: var(--bs-btn-bg);
	color: var(--bs-btn-color) !important;
	font-size: 20px;
	font-weight: 700;
	line-height: 1.2;
	text-decoration: none !important;
	box-shadow: 0 10px 22px color-mix(in srgb, var(--bs-btn-bg) 32%, transparent);
	transition: background-color 0.3s ease, transform 0.25s ease, box-shadow 0.3s ease;
}
.bs-btn-w-auto .bs-btn {
	width: auto;
	align-self: var(--bs-just, flex-start);
}
.bs-btn:hover,
.bs-btn:focus {
	background: var(--bs-btn-hover);
	color: var(--bs-btn-color) !important;
}
.bs-btn-icon {
	display: inline-flex;
	align-items: center;
}
.bs-btn-icon svg {
	width: 1.15em;
	height: 1.15em;
}
.bs-btn-arrow svg { width: 1em; height: 1em; }
.bs-btn-arrow { transition: transform 0.3s ease; }
.bs-btn:hover .bs-btn-arrow { transform: translateX(5px); }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
	.bs-title { font-size: 22px; }
	.bs-subtitle { font-size: 17px; }
	.bs-price-sale { font-size: 23px; }
	.bs-btn { font-size: 18px; }
}
@media (max-width: 767px) {
	.bs-card { padding: 20px; border-radius: 20px; }
	.bs-media { height: 290px; margin-bottom: 16px; }
	.bs-img { width: 74%; }
	.bs-tag { padding: 8px 16px; font-size: 14px; }
	.bs-usps { flex-wrap: wrap; row-gap: 12px; }
	.bs-usp { flex: 1 1 45%; }
	.bs-btn { font-size: 17px; padding: 14px 20px; }
}
@media (max-width: 420px) {
	.bs-usp { flex: 1 1 100%; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
	.bs-card,
	.bs-img img,
	.bs-btn,
	.bs-btn-arrow {
		transition: none;
	}
	.bs-lift-yes .bs-card:hover { transform: none; }
}
