﻿/* ==========================================================================
   TEKCRAFT — Home projects grid card (neon device mockup)
   ========================================================================== */

/* 4 cards per row in the home #portfolio grid */
#portfolio .portfolio-grid-modern.qeema-portfolio-grid {
	grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
	gap: 28px !important;
	max-width: 1240px;
	margin-inline: auto;
}

/* Filter bar: glass capsule with icon pills */
#portfolio .portfolio-filters {
	display: flex !important;
	justify-content: center !important;
	flex-wrap: wrap !important;
	gap: 8px !important;
	width: fit-content !important;
	max-width: 100% !important;
	margin: 0 auto 38px !important;
	padding: 8px !important;
	border-radius: 20px !important;
	background: rgba(13, 16, 52, .6) !important;
	border: 1px solid rgba(129, 140, 248, .16) !important;
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, .05), 0 10px 30px rgba(0, 0, 0, .35) !important;
	backdrop-filter: blur(12px);
}

#portfolio .portfolio-filters .filter-btn {
	display: inline-flex !important;
	align-items: center !important;
	gap: 9px !important;
	margin: 0 !important;
	padding: 10px 20px !important;
	min-height: 0 !important;
	border-radius: 14px !important;
	font: 500 14px/1.2 "Rubik", sans-serif !important;
	color: #c9c7ec !important;
	background: rgba(22, 26, 80, .7) !important;
	border: 1px solid rgba(129, 140, 248, .16) !important;
	box-shadow: none !important;
	transform: none !important;
	transition: color .25s, border-color .25s, background .25s, box-shadow .25s !important;
}

#portfolio .portfolio-filters .filter-btn i {
	font-size: 13px;
	color: #8b93f8;
	transition: color .25s;
}

#portfolio .portfolio-filters .filter-btn:hover {
	color: #fff !important;
	border-color: rgba(34, 211, 238, .45) !important;
	background: rgba(28, 34, 100, .85) !important;
}

#portfolio .portfolio-filters .filter-btn:hover i { color: #22d3ee; }

#portfolio .portfolio-filters .filter-btn.active {
	color: #fff !important;
	border-color: transparent !important;
	background:
		linear-gradient(rgba(12, 28, 86, .96), rgba(12, 28, 86, .96)) padding-box,
		linear-gradient(90deg, #22d3ee, #a855f7) border-box !important;
	box-shadow: 0 0 18px rgba(34, 211, 238, .4), inset 0 0 14px rgba(34, 211, 238, .16) !important;
}

#portfolio .portfolio-filters .filter-btn.active i { color: #22d3ee; }

@media (max-width: 768px) {
	#portfolio .portfolio-filters {
		flex-wrap: nowrap !important;
		justify-content: flex-start !important;
		width: 100% !important;
		overflow-x: auto !important;
		scrollbar-width: none;
	}

	#portfolio .portfolio-filters::-webkit-scrollbar { display: none; }
	#portfolio .portfolio-filters .filter-btn { flex: 0 0 auto !important; padding: 9px 16px !important; font-size: 13px !important; }
}

@media (max-width: 1200px) {
	#portfolio .portfolio-grid-modern.qeema-portfolio-grid {
		grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
	}
}

@media (max-width: 960px) {
	#portfolio .portfolio-grid-modern.qeema-portfolio-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
	}
}

.tkp-card *,
.tkp-card *::before,
.tkp-card *::after { box-sizing: border-box; }

.tkp-card h3,
.tkp-card p,
.tkp-card ul { margin: 0; padding: 0; }

.tkp-card {
	--c-cyan: #22d3ee;
	--c-blue: #3b82f6;
	--c-purple: #a855f7;
	--c-magenta: #d946ef;
	--c-pink: #ec4899;
	--txt-2: #b9b6e3;
	--a1: var(--c-purple);
	--a2: var(--c-magenta);
	--glow: rgba(168, 85, 247, .45);

	position: relative;
	min-width: 0;
	color: #fff;
	font-family: "Rubik", sans-serif;
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	padding: 14px 14px 18px;
	border-radius: 18px;
	border: 1px solid rgba(255, 255, 255, .08);
	background: linear-gradient(180deg, rgba(18, 20, 52, .9), rgba(10, 11, 32, .95));
	box-shadow: 0 16px 36px -24px rgba(0, 0, 0, .9);
	transition: transform .35s, border-color .35s, box-shadow .35s;
}

.tkp-card:hover {
	transform: translateY(-4px);
	border-color: color-mix(in srgb, var(--a1) 45%, transparent);
	box-shadow: 0 20px 40px -24px var(--glow);
}
.tkp-card--cyan { --a1: var(--c-cyan); --a2: var(--c-blue); --glow: rgba(34, 211, 238, .4); }
.tkp-card--pink { --a1: var(--c-magenta); --a2: var(--c-pink); --glow: rgba(217, 70, 239, .45); }

.tkp-chip {
	align-self: flex-start;
	display: inline-flex;
	align-items: center;
	gap: 7px;
	padding: 4px 11px;
	border-radius: 999px;
	font-size: 12px;
	font-weight: 500;
	color: #c7cbe8;
	background: rgba(255, 255, 255, .04);
	border: 1px solid rgba(255, 255, 255, .08);
}

.tkp-chip i {
	font-size: 11px;
	color: var(--a1);
}

.tkp-media {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 175px;
	margin: 12px 0 14px;
	flex-shrink: 0;
	border-radius: 12px;
	background: rgba(255, 255, 255, .025);
}

.tkp-media__halo,
.tkp-card .tkp-tile { display: none; }

/* Soft floor shadow under the devices */
.tkp-media::after {
	content: "";
	position: absolute;
	left: 18%;
	right: 18%;
	bottom: 2px;
	height: 14px;
	border-radius: 50%;
	background: radial-gradient(closest-side, rgba(0, 0, 0, .55), transparent);
	pointer-events: none;
}

.tkp-device { position: relative; display: block; transition: transform .45s; }
.tkp-card:hover .tkp-device--phone { transform: translateY(-3px); }
.tkp-device__screen { position: relative; display: block; overflow: hidden; background: #0b1030; }

/* Laptop + mini phone combo */
.tkp-combo {
	position: relative;
	display: flex;
	justify-content: center;
	width: 100%;
	transition: transform .45s;
}

.tkp-card:hover .tkp-combo { transform: translateY(-3px); }

.tkp-device--mini {
	position: absolute;
	z-index: 2;
	right: 5%;
	bottom: -8px;
	width: 46px;
}

.tkp-device--mini .tkp-device__screen {
	aspect-ratio: 9 / 19;
	border: 4px solid #0a0b1c;
	border-radius: 14px;
	box-shadow: 0 0 0 1px rgba(196, 181, 253, .55), 0 10px 20px rgba(0, 0, 0, .6);
}

/* Placeholder UI when a project has no image */
.tkp-skel {
	position: absolute;
	inset: 0;
	display: flex;
	flex-direction: column;
	gap: 6%;
	padding: 7%;
	background: linear-gradient(160deg, #141a52, #0b0f33);
}

.tkp-skel__bar { height: 8%; border-radius: 3px; background: rgba(255, 255, 255, .08); }

.tkp-skel__hero {
	flex: 1;
	display: grid;
	place-items: center;
	border-radius: 5px;
	font-size: 24px;
	color: #fff;
	background: linear-gradient(120deg, var(--a1), var(--a2));
	opacity: .85;
}

.tkp-skel__row { display: flex; gap: 6%; height: 18%; }
.tkp-skel__row span { flex: 1; border-radius: 4px; background: rgba(255, 255, 255, .08); }
.tkp-device--mini .tkp-skel,
.tkp-device--phone .tkp-skel { padding: 12% 10%; }
.tkp-device--mini .tkp-skel__hero i { font-size: 12px; }

.tkp-card .tkp-device__img {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	max-width: none;
	object-fit: cover;
	object-position: top center;
}

.tkp-device__ph {
	position: absolute;
	inset: 0;
	display: grid;
	place-items: center;
	font-size: 34px;
	color: var(--a1);
	text-shadow: 0 0 18px var(--glow);
	background: radial-gradient(circle at 50% 40%, rgba(99, 102, 241, .25), transparent 70%);
}

.tkp-device--laptop { width: 80%; max-width: 240px; }

.tkp-device--laptop .tkp-device__screen {
	aspect-ratio: 16 / 10;
	border: 6px solid #0a0b1c;
	border-bottom-width: 8px;
	border-radius: 10px 10px 0 0;
	box-shadow: 0 0 0 1px rgba(165, 180, 252, .35), 0 18px 30px rgba(0, 0, 0, .55);
}

.tkp-device--laptop::after {
	content: "";
	display: block;
	width: 118%;
	height: 9px;
	margin-inline: -9%;
	border-radius: 0 0 12px 12px;
	background: linear-gradient(180deg, #c7cbe0, #6b7095 55%, #2a2d4a);
	box-shadow: 0 10px 18px rgba(0, 0, 0, .5);
}

.tkp-device--phone { width: 84px; }

.tkp-device--phone .tkp-device__screen {
	aspect-ratio: 9 / 19;
	border: 5px solid #0a0b1c;
	border-radius: 22px;
	box-shadow: 0 0 0 1.5px rgba(196, 181, 253, .55), 0 18px 30px rgba(0, 0, 0, .55);
}

.tkp-device--phone .tkp-device__screen::before {
	content: "";
	position: absolute;
	z-index: 1;
	top: 4px;
	left: 50%;
	translate: -50% 0;
	width: 34%;
	height: 8px;
	border-radius: 6px;
	background: #0a0b1c;
}

.tkp-tile {
	position: absolute;
	z-index: 2;
	width: 40px;
	height: 40px;
	border-radius: 12px;
	display: grid;
	place-items: center;
	color: #fff;
	font-size: 18px;
	background: linear-gradient(145deg, rgba(99, 102, 241, .95), rgba(76, 29, 149, .95));
	border: 1px solid rgba(196, 181, 253, .5);
	box-shadow: 0 0 16px rgba(129, 140, 248, .6);
}

.tkp-tile--a { right: 12%; top: 30%; }
.tkp-tile--b { left: 4%; top: 14%; }

.tkp-device--phone ~ .tkp-tile--b {
	left: 12%;
	top: 52%;
	bottom: auto;
	background: linear-gradient(145deg, rgba(34, 197, 94, .9), rgba(21, 128, 61, .95));
	border-color: rgba(134, 239, 172, .5);
	box-shadow: 0 0 16px rgba(34, 197, 94, .5);
}

.tkp-card .tkp-title {
	width: 100%;
	margin-bottom: 6px;
	font-size: 17px;
	font-weight: 700;
	line-height: 1.35;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.tkp-card .tkp-title a { color: #fff; text-decoration: none; }

.tkp-card .tkp-desc {
	margin-bottom: 14px;
	min-height: 3.6em;
	font-size: 13px;
	line-height: 1.8;
	color: #9ea6c4;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.tkp-desc mark { background: none; color: var(--c-cyan); font-weight: 500; }

.tkp-card .tkp-feats {
	list-style: none;
	display: flex;
	justify-content: center;
	gap: 6px;
	flex-wrap: nowrap;
	width: 100%;
	overflow: hidden;
	margin-bottom: 18px;
}

.tkp-feats li {
	flex: 0 1 auto;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	min-width: 0;
	padding: 4px 9px;
	border-radius: 8px;
	font-size: 11px;
	color: #b9bfdc;
	background: rgba(255, 255, 255, .04);
	border: 1px solid rgba(255, 255, 255, .07);
}

.tkp-feats li:nth-child(n+3) { display: none; }

.tkp-feats__ic {
	flex: none;
	font-size: 10px;
	color: var(--a1);
}

.tkp-feats__tx { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.tkp-card .tkp-cta {
	margin-top: auto;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	width: 100%;
	padding: 10px 16px;
	border-radius: 12px;
	text-decoration: none;
	color: #e7ebff;
	font-weight: 600;
	font-size: 13.5px;
	background: rgba(255, 255, 255, .04);
	border: 1px solid rgba(255, 255, 255, .1);
	transition: background .3s, border-color .3s, color .3s;
}

.tkp-card .tkp-cta:hover {
	color: #fff;
	background: linear-gradient(90deg, var(--a1), var(--a2));
	border-color: transparent;
}

.tkp-cta__eye { display: none; }

.tkp-cta__arrow { font-size: 13px; transition: translate .3s; }
.tkp-cta:hover .tkp-cta__arrow { translate: -4px 0; }
html[dir="ltr"] .tkp-cta:hover .tkp-cta__arrow { translate: 4px 0; }

/* Mobile: home grid becomes a swipe track (responsive-fix.css) — size the cards for it */
@media (max-width: 768px) {
	#portfolio .portfolio-grid-modern.qeema-portfolio-grid .tkp-card {
		flex: 0 0 86% !important;
		width: 86% !important;
		max-width: 360px !important;
		min-width: 280px !important;
		scroll-snap-align: center !important;
		margin: 0 !important;
	}

	#portfolio .portfolio-grid-modern.qeema-portfolio-grid .tkp-card[style*="display: none"] { display: none !important; }
	.tkp-media { height: 220px; }
}
