/* ═══════════════════════════════════════════
   Solid Addons — Content Showcase Widget
   ═══════════════════════════════════════════ */

.solidae-showcase {
	position: relative;
	display: grid;
	gap: 20px;
	box-sizing: border-box;
	font-family: inherit;
}

.solidae-showcase *,
.solidae-showcase *::before,
.solidae-showcase *::after {
	box-sizing: border-box;
}

/* ─── Grid columns ─── */

.solidae-showcase--cols-2 { grid-template-columns: repeat(2, 1fr); }
.solidae-showcase--cols-3 { grid-template-columns: repeat(3, 1fr); }
.solidae-showcase--cols-4 { grid-template-columns: repeat(4, 1fr); }
.solidae-showcase--cols-5 { grid-template-columns: repeat(5, 1fr); }
.solidae-showcase--cols-6 { grid-template-columns: repeat(6, 1fr); }

/* ═══════════════════════════════════════════
   CARD
   ═══════════════════════════════════════════ */

.solidae-showcase__card {
	position: relative;
	display: flex;
	flex-direction: column;
	background: #ffffff;
	border: 1px solid #e5e7eb;
	border-radius: 12px;
	overflow: hidden;
	cursor: pointer;
	transition: background-color 200ms ease,
		border-color 200ms ease,
		box-shadow 200ms ease,
		transform 200ms ease;
	-webkit-tap-highlight-color: transparent;
}

.solidae-showcase__card:hover {
	border-color: #d1d5db;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
	transform: translateY(-2px);
}

.solidae-showcase__card:focus-visible {
	outline: 2px solid #1a1a1a;
	outline-offset: 2px;
}

/* Active card */
.solidae-showcase__card.is-active {
	border-color: #1a1a1a;
	box-shadow: 0 0 0 1px #1a1a1a;
}

/* ─── Card media ─── */

.solidae-showcase__card-media {
	overflow: hidden;
	line-height: 0;
}

.solidae-showcase__card-media img {
	display: block;
	width: 100%;
	height: 200px;
	object-fit: cover;
	transition: transform 400ms ease;
}

.solidae-showcase__card:hover .solidae-showcase__card-media img {
	transform: scale(1.04);
}

/* ─── Card body ─── */

.solidae-showcase__card-body {
	padding: 16px 20px;
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.solidae-showcase__card-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	flex-shrink: 0;
	margin-bottom: 4px;
	color: #1a1a1a;
}

.solidae-showcase__card-icon i,
.solidae-showcase__card-icon svg {
	font-size: 20px;
	width: 20px;
	height: 20px;
}

.solidae-showcase__card-title {
	margin: 0;
	font-size: 16px;
	font-weight: 700;
	color: #1a1a1a;
	line-height: 1.3;
}

.solidae-showcase__card-subtitle {
	font-size: 13px;
	color: #6b7280;
	line-height: 1.4;
}

/* ═══════════════════════════════════════════
   PANEL
   ═══════════════════════════════════════════ */

.solidae-showcase__panel {
	grid-column: 1 / -1;
	display: none;
}

.solidae-showcase__panel.is-open {
	display: block;
}

.solidae-showcase__panel-inner {
	display: flex;
	align-items: stretch;
	background: #f8f9fa;
	border: 1px solid #e5e7eb;
	border-radius: 12px;
	overflow: hidden;
	position: relative;
}

/* Image position: right */
.solidae-showcase--img-right .solidae-showcase__panel-inner {
	flex-direction: row-reverse;
}

/* Image position: top */
.solidae-showcase--img-top .solidae-showcase__panel-inner {
	flex-direction: column;
}

.solidae-showcase--img-top .solidae-showcase__panel-media {
	flex: 0 0 auto;
	max-height: 360px;
}

/* No image — panel is content-only */
.solidae-showcase--no-image .solidae-showcase__panel-media {
	display: none;
}

.solidae-showcase--no-image .solidae-showcase__panel-content {
	flex: 1;
}

/* ─── Panel media ─── */

.solidae-showcase__panel-media {
	flex: 0 0 50%;
	overflow: hidden;
	line-height: 0;
}

.solidae-showcase__panel-media img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

/* ─── Panel content ─── */

.solidae-showcase__panel-content {
	flex: 1;
	padding: 40px 36px;
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 16px;
}

.solidae-showcase__panel-title {
	margin: 0;
	font-size: 26px;
	font-weight: 700;
	color: #1a1a1a;
	line-height: 1.25;
}

.solidae-showcase__panel-desc {
	font-size: 15px;
	line-height: 1.6;
	color: #6b7280;
	margin: 0;
}

/* ─── Panel buttons ─── */

.solidae-showcase__panel-buttons {
	display: flex;
	gap: 12px;
	flex-wrap: wrap;
	margin-top: 8px;
}

.solidae-showcase__btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	font-size: 15px;
	font-weight: 600;
	text-decoration: none;
	border: 0 solid transparent;
	transition: color 200ms ease,
		background-color 200ms ease,
		border-color 200ms ease,
		transform 200ms ease,
		box-shadow 200ms ease;
	line-height: 1.2;
	cursor: pointer;
}

.solidae-showcase__btn--primary {
	padding: 12px 24px;
	background: #1a1a1a;
	color: #ffffff;
	border-radius: 8px;
}

.solidae-showcase__btn--primary:hover {
	background: #333333;
	color: #ffffff;
}

.solidae-showcase__btn--secondary {
	padding: 12px 24px;
	background: transparent;
	color: #1a1a1a;
	border: 2px solid #1a1a1a;
	border-radius: 8px;
}

.solidae-showcase__btn--secondary:hover {
	background: #1a1a1a;
	color: #ffffff;
}

.solidae-showcase__btn-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	line-height: 1;
}

.solidae-showcase__btn-icon i,
.solidae-showcase__btn-icon svg {
	width: 1em;
	height: 1em;
	font-size: 16px;
}

/* ─── Close button ─── */

.solidae-showcase__panel-close {
	position: absolute;
	top: 16px;
	right: 16px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background: rgba(0, 0, 0, 0.06);
	border: 0;
	border-radius: 50%;
	cursor: pointer;
	color: #6b7280;
	padding: 9px;
	line-height: 0;
	transition: background-color 150ms ease, color 150ms ease;
	z-index: 5;
}

.solidae-showcase__panel-close svg {
	width: 18px;
	height: 18px;
	display: block;
}

.solidae-showcase__panel-close:hover {
	background: rgba(0, 0, 0, 0.12);
	color: #1a1a1a;
}

/* ═══════════════════════════════════════════
   OVERLAY MODE
   ═══════════════════════════════════════════ */

.solidae-showcase--overlay .solidae-showcase__panel {
	position: absolute;
	left: 0;
	right: 0;
	z-index: 10;
}

/* ═══════════════════════════════════════════
   EDITOR PREVIEW
   ═══════════════════════════════════════════ */

.solidae-showcase--editor-empty {
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 40px 20px;
	background: #f8f9fa;
	border: 2px dashed #d1d5db;
	border-radius: 12px;
	color: #6b7280;
	font-size: 14px;
}

/* ═══════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════ */

@media (max-width: 991px) {
	.solidae-showcase {
		grid-template-columns: repeat(2, 1fr) !important;
	}
}

@media (max-width: 767px) {
	.solidae-showcase {
		grid-template-columns: 1fr !important;
	}

	.solidae-showcase__panel-inner {
		flex-direction: column !important;
	}

	.solidae-showcase__panel-media {
		flex: 0 0 auto;
		max-height: 300px;
	}

	.solidae-showcase__panel-content {
		padding: 24px 20px;
	}

	.solidae-showcase__panel-buttons {
		flex-direction: column;
	}

	.solidae-showcase__btn {
		width: 100%;
	}
}
