/**
 * TechBBQ Previous Projects card — Figma cardProgram (Previous Projects page).
 *
 * Figma refs:
 * - 1440: node 5866:41408
 * - 375:  node 7384:79349
 *
 * Breakpoints (mobile-first): 0–767 (base), 768–1023, 1024–1439, 1440+.
 */

.techbbq-previous-project-card {
	/* Set per card by the Card Colour control, and inherited by nothing: a card with no colour
	 * chosen keeps `transparent`, which makes the tint below render as nothing at all. That is what
	 * lets this live in the theme without changing any page that has not asked for it. */
	--pp-tint: transparent;

	position: relative;
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	justify-content: center;
	min-height: 360px;
	padding: 20px;
	overflow: hidden;
	isolation: isolate;
	border-radius: 12px;
	background-color: var(--techbbq-bg-surface);
	color: var(--techbbq-content-primary);
}

/* The tint itself: a wash from the top right plus a hairline ring, both mixed down from --pp-tint
 * so one colour drives the whole treatment. Lifted out of the per-page Custom CSS on Previous
 * Projects and Current Projects so any page using these cards gets it, and so the colour can come
 * from a control instead of an nth-child rule. Those two pages still carry their own copy of this,
 * at higher specificity and with identical declarations, until it is deleted. */
.techbbq-previous-project-card::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 0;
	pointer-events: none;
	border-radius: inherit;
	background: radial-gradient(
		135% 100% at 82% 0%,
		color-mix(in srgb, var(--pp-tint) 18%, transparent) 0%,
		color-mix(in srgb, var(--pp-tint) 6%, transparent) 38%,
		transparent 70%
	);
	box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--pp-tint) 14%, transparent);
	opacity: 0.85;
	transition: opacity 0.35s ease;
}

.techbbq-previous-project-card:hover::before {
	opacity: 1;
}

.techbbq-previous-project-card > * {
	position: relative;
	z-index: 1;
}

a.techbbq-previous-project-card {
	text-decoration: none;
	color: inherit;
	cursor: pointer;
	transition: background-color 0.2s ease;
}

a.techbbq-previous-project-card:hover,
a.techbbq-previous-project-card:focus-visible {
	background-color: var(--techbbq-bg-surface-alt);
	color: inherit;
	text-decoration: none;
}

a.techbbq-previous-project-card:hover *,
a.techbbq-previous-project-card:focus-visible * {
	text-decoration: none;
}

a.techbbq-previous-project-card:focus-visible {
	outline: 2px solid var(--techbbq-content-primary);
	outline-offset: 2px;
}

.techbbq-previous-project-card__inner {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	justify-content: space-between;
	width: 100%;
	min-height: 0;
}

.techbbq-previous-project-card__logo-wrap {
	display: flex;
	flex-shrink: 0;
	justify-content: flex-end;
	width: 100%;
}

.techbbq-previous-project-card__logo {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	max-width: 100%;
	max-height: 53px;
	overflow: hidden;
}

.techbbq-previous-project-card__logo-image {
	display: block;
	max-width: 100%;
	max-height: 53px;
	width: auto;
	height: auto;
	object-fit: contain;
	object-position: right center;
}

.techbbq-previous-project-card__content {
	display: flex;
	flex-direction: column;
	gap: var(--techbbq-space-1);
	align-items: flex-start;
	width: 100%;
}

.techbbq-previous-project-card__title {
	margin: 0;
}

.techbbq-previous-project-card__description {
	margin: 0;
	color: var(--techbbq-content-secondary);
}
