/*
 * Gemkibo Featured Product Card — SEPARATE BEM namespace (2026-05-28)
 *
 * Hero-style col-span-2 tile for shop archive featured slots.
 * Fully isolated from `.gk-product-card.*` (LOCKED template).
 *
 * Variants:
 *   .gk-product-card-featured--a   image LEFT, content RIGHT (idx 1, 13, 25...)
 *   .gk-product-card-featured--b   image RIGHT, content LEFT (idx 7, 19, 31...)
 *
 * State:
 *   .gk-product-card-featured--on-sale       price tier (visual ready)
 *   .gk-product-card-featured--out-of-stock  CTA disabled
 *
 * Research-backed:
 *   - 4:5 image ratio (Baymard 2023)
 *   - Hero featured product layout (Baymard 2024 — premium cards)
 *   - Visible CTA +28% (Baymard 2024)
 *   - Anchoring duża cena + Omnibus crossed-out (sila-perswazji.md)
 *   - Solid colors only on text (memory feedback_no_transparent_font_colors)
 *
 * Vanilla CSS. !important używane TYLKO przy override z gk-archive-v5-body scope
 * (woocommerce shop-archive cascade specificity).
 */

/* ═══════════════════════════════════════════════════════════════
 * TOKENS — local scope --gkpc-feat-* (no global pollution)
 * ═══════════════════════════════════════════════════════════════ */
.gk-product-card-featured {
	--gkpc-feat-brand:          #5DA935;
	--gkpc-feat-brand-hover:    #4F9028;
	--gkpc-feat-brand-dark:     #1F3D14;
	--gkpc-feat-emerald:        #009668;
	--gkpc-feat-cream:          #FAF8F4;
	--gkpc-feat-soft-green:     #E3F2D1;
	--gkpc-feat-text-dark:      #1F3D14;
	--gkpc-feat-text:           #111827;
	--gkpc-feat-text-muted:     #4B5563;
	--gkpc-feat-text-faint:     #9CA3AF;
	--gkpc-feat-border:         rgba(31, 61, 20, 0.10);
	--gkpc-feat-danger:         #DC2626;
	--gkpc-feat-radius:         20px;
	--gkpc-feat-radius-pill:    9999px;
	--gkpc-feat-shadow:         0 1px 3px rgba(0,0,0,0.04), 0 12px 32px -10px rgba(31, 61, 20, 0.16);
	--gkpc-feat-shadow-hover:   0 4px 12px rgba(0,0,0,0.06), 0 24px 60px -12px rgba(31, 61, 20, 0.26);
	--gkpc-feat-ease:           cubic-bezier(0.16, 1, 0.3, 1);
	--gkpc-feat-font-display:   'Playfair Display', Georgia, serif;
	--gkpc-feat-font-body:      'Inter', system-ui, -apple-system, sans-serif;

	/* Root container */
	position: relative;
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
	gap: 0;
	width: 100%;
	height: 100%;
	min-height: 480px;
	background: linear-gradient(135deg, var(--gkpc-feat-cream) 0%, #ffffff 100%);
	border: 1px solid var(--gkpc-feat-border);
	border-radius: var(--gkpc-feat-radius);
	box-shadow: var(--gkpc-feat-shadow);
	overflow: hidden;
	text-align: left;
	font-family: var(--gkpc-feat-font-body);
	transition:
		transform 360ms var(--gkpc-feat-ease),
		box-shadow 360ms var(--gkpc-feat-ease),
		border-color 360ms ease;
}

.gk-product-card-featured:hover {
	transform: translateY(-6px);
	border-color: rgba(93, 169, 53, 0.30);
	box-shadow: var(--gkpc-feat-shadow-hover);
}

/* Variant accent borders — visual differentiation A vs B */
.gk-product-card-featured--a {
	border-left: 4px solid var(--gkpc-feat-emerald);
}
.gk-product-card-featured--b {
	border-right: 4px solid var(--gkpc-feat-emerald);
}

/* Variant order swap — A image left, B image right */
.gk-product-card-featured--a .gk-product-card-featured__media   { order: 1; }
.gk-product-card-featured--a .gk-product-card-featured__content { order: 2; }
.gk-product-card-featured--b .gk-product-card-featured__media   { order: 2; }
.gk-product-card-featured--b .gk-product-card-featured__content { order: 1; }

/* ═══════════════════════════════════════════════════════════════
 * MEDIA — 4:5 aspect, cover, hover scale
 * ═══════════════════════════════════════════════════════════════ */
.gk-product-card-featured__media {
	position: relative;
	display: block;
	width: 100%;
	height: 100%;
	min-height: 480px;
	background: var(--gkpc-feat-cream);
	overflow: hidden;
	text-decoration: none;
}

.gk-product-card-featured__image {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 600ms var(--gkpc-feat-ease);
}

.gk-product-card-featured:hover .gk-product-card-featured__image {
	transform: scale(1.04);
}

/* ═══════════════════════════════════════════════════════════════
 * RIBBON — top-left pill, forest-dark base
 * ═══════════════════════════════════════════════════════════════ */
.gk-product-card-featured__ribbon {
	position: absolute;
	top: 20px;
	left: 20px;
	z-index: 4;
	display: inline-flex;
	align-items: center;
	padding: 8px 16px;
	background: var(--gkpc-feat-brand-dark);
	color: #ffffff;
	font-family: var(--gkpc-feat-font-body);
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.15em;
	text-transform: uppercase;
	line-height: 1;
	border-radius: var(--gkpc-feat-radius-pill);
	box-shadow: 0 4px 14px rgba(31, 61, 20, 0.28);
	pointer-events: none;
	max-width: calc(100% - 40px);
	white-space: nowrap;
}

/* ═══════════════════════════════════════════════════════════════
 * HEART — top-LEFT, offset DOWN pod ribbon (44x44 white circle)
 * ═══════════════════════════════════════════════════════════════ */
.gk-product-card-featured__heart {
	position: absolute;
	top: 60px;       /* pod ribbon (ribbon ends ~52px) */
	left: 20px;
	z-index: 5;
}

.gk-product-card-featured__heart-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	margin: 0;
	padding: 0;
	background: #ffffff;
	border: 1px solid var(--gkpc-feat-border);
	border-radius: 50%;
	color: var(--gkpc-feat-text-dark);
	cursor: pointer;
	box-shadow: 0 2px 8px rgba(0,0,0,0.10);
	transition: transform 180ms var(--gkpc-feat-ease), color 180ms ease, background 180ms ease;
}

.gk-product-card-featured__heart-btn:hover {
	transform: scale(1.08);
	color: var(--gkpc-feat-danger);
}

.gk-product-card-featured__heart-btn:focus-visible {
	outline: 2px solid var(--gkpc-feat-brand);
	outline-offset: 2px;
}

/* YITH wishlist normalize w heart scope — circle button 44x44 */
.gk-product-card-featured__heart .yith-wcwl-add-to-wishlist,
.gk-product-card-featured__heart .yith-add-to-wishlist-button-block {
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	width: 44px !important;
	height: 44px !important;
	margin: 0 !important;
	padding: 0 !important;
	background: transparent !important;
	border: 0 !important;
	color: var(--gkpc-feat-text-dark);
}

.gk-product-card-featured__heart .yith-wcwl-add-to-wishlist-button,
.gk-product-card-featured__heart .yith-wcwl-add-to-wishlist-button--custom-button,
.gk-product-card-featured__heart .yith-wcwl-add-button button,
.gk-product-card-featured__heart .yith-wcwl-add-to-wishlist a {
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	width: 44px !important;
	height: 44px !important;
	margin: 0 !important;
	padding: 0 !important;
	background: #ffffff !important;
	border: 1px solid var(--gkpc-feat-border) !important;
	border-radius: 50% !important;
	color: var(--gkpc-feat-text-dark) !important;
	cursor: pointer;
	box-shadow: 0 2px 8px rgba(0,0,0,0.10);
	font-size: 0 !important;       /* hide YITH label text */
	text-decoration: none !important;
	transition: transform 180ms var(--gkpc-feat-ease), color 180ms ease;
	line-height: 1 !important;
	min-width: 44px;
}

.gk-product-card-featured__heart .yith-wcwl-add-to-wishlist-button:hover,
.gk-product-card-featured__heart .yith-wcwl-add-to-wishlist a:hover {
	transform: scale(1.08);
	color: var(--gkpc-feat-danger) !important;
	background: #ffffff !important;
}

.gk-product-card-featured__heart .yith-wcwl-icon,
.gk-product-card-featured__heart .yith-wcwl-icon-svg,
.gk-product-card-featured__heart .yith-wcwl-icon-svg__wrapper,
.gk-product-card-featured__heart .yith-wcwl-add-to-wishlist svg,
.gk-product-card-featured__heart .yith-wcwl-add-to-wishlist i {
	font-size: 18px !important;
	width: 20px !important;
	height: 20px !important;
	color: inherit !important;
	line-height: 1 !important;
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
}

.gk-product-card-featured__heart .yith-wcwl-add-to-wishlist-button-label,
.gk-product-card-featured__heart .feedback,
.gk-product-card-featured__heart .yith-wcwl-wishlistaddedbrowse,
.gk-product-card-featured__heart .yith-wcwl-wishlistexistsbrowse {
	display: none !important;
}

/* ═══════════════════════════════════════════════════════════════
 * BADGES — top-right horizontal stack
 * ═══════════════════════════════════════════════════════════════ */
.gk-product-card-featured__badges {
	position: absolute;
	top: 20px;
	right: 20px;
	z-index: 4;
	display: flex;
	flex-direction: row;
	gap: 8px;
	align-items: center;
	pointer-events: none;
}

.gk-product-card-featured__badge {
	display: inline-flex;
	align-items: center;
	padding: 6px 12px;
	font-family: var(--gkpc-feat-font-body);
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	line-height: 1;
	border-radius: var(--gkpc-feat-radius-pill);
	color: #ffffff;
	box-shadow: 0 2px 8px rgba(0,0,0,0.18);
	white-space: nowrap;
}

.gk-product-card-featured__badge--promo {
	background: var(--gkpc-feat-danger);
}
.gk-product-card-featured__badge--bestseller {
	background: var(--gkpc-feat-brand);
}
.gk-product-card-featured__badge--new {
	background: var(--gkpc-feat-emerald);
}

/* ═══════════════════════════════════════════════════════════════
 * CONTENT — eyebrow / title / excerpt / price / CTA
 * ═══════════════════════════════════════════════════════════════ */
.gk-product-card-featured__content {
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 16px;
	padding: 40px clamp(28px, 4vw, 48px);
	min-width: 0;
}

.gk-product-card-featured__eyebrow {
	display: inline-block;
	font-family: var(--gkpc-feat-font-body);
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.20em;
	text-transform: uppercase;
	color: var(--gkpc-feat-emerald);
	line-height: 1;
}

.gk-product-card-featured__title {
	margin: 0;
	font-family: var(--gkpc-feat-font-display);
	font-size: clamp(24px, 2vw, 32px);
	font-weight: 600;
	line-height: 1.12;
	color: var(--gkpc-feat-text-dark);
	letter-spacing: -0.01em;
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.gk-product-card-featured__title a {
	color: inherit;
	text-decoration: none;
	transition: color 200ms ease;
}

.gk-product-card-featured__title a:hover {
	color: var(--gkpc-feat-emerald);
}

.gk-product-card-featured__excerpt {
	margin: 0;
	font-family: var(--gkpc-feat-font-body);
	font-size: 15px;
	font-weight: 400;
	line-height: 1.55;
	color: var(--gkpc-feat-text-muted);
	max-width: 52ch;
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

/* ═══════════════════════════════════════════════════════════════
 * PRICE — duża 32px Playfair + crossed regular + Omnibus mini
 * ═══════════════════════════════════════════════════════════════ */
.gk-product-card-featured__price-block {
	display: flex;
	flex-direction: column;
	gap: 4px;
}

.gk-product-card-featured__price {
	display: inline-flex;
	align-items: baseline;
	gap: 10px;
	flex-wrap: wrap;
	font-family: var(--gkpc-feat-font-display);
	font-size: 32px;
	font-weight: 700;
	line-height: 1.1;
	color: var(--gkpc-feat-text-dark);
}

.gk-product-card-featured__price .price {
	font-family: inherit;
	font-size: inherit;
	color: inherit;
	margin: 0;
}

.gk-product-card-featured__price ins,
.gk-product-card-featured__price ins .woocommerce-Price-amount {
	background: transparent;
	text-decoration: none;
	font-family: inherit;
	font-size: inherit;
	font-weight: inherit;
	color: var(--gkpc-feat-text-dark);
}

.gk-product-card-featured__price del,
.gk-product-card-featured__price del .woocommerce-Price-amount {
	font-family: var(--gkpc-feat-font-body);
	font-size: 18px;
	font-weight: 400;
	color: var(--gkpc-feat-text-faint);
	text-decoration: line-through;
	opacity: 1;
}

.gk-product-card-featured__omnibus {
	margin: 0;
	font-family: var(--gkpc-feat-font-body);
	font-size: 10px;
	font-style: italic;
	color: var(--gkpc-feat-text-muted);
	line-height: 1.4;
}

/* Hide iworks-omnibus default plugin output inside featured card */
.gk-product-card-featured .iworks-omnibus,
.gk-product-card-featured .iworks_omnibus,
.gk-product-card-featured__price + .iworks-omnibus {
	display: none !important;
}

/* ═══════════════════════════════════════════════════════════════
 * CTA — forest-dark base, emerald hover, full-width pill
 * ═══════════════════════════════════════════════════════════════ */
.gk-product-card-featured__cta {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	margin-top: 8px;
	padding: 14px 24px;
	width: 100%;
	max-width: 320px;
	background: var(--gkpc-feat-brand-dark);
	color: #ffffff;
	font-family: var(--gkpc-feat-font-body);
	font-size: 15px;
	font-weight: 600;
	letter-spacing: 0.02em;
	line-height: 1;
	border: 0;
	border-radius: var(--gkpc-feat-radius-pill);
	cursor: pointer;
	text-decoration: none;
	box-shadow: 0 8px 24px -6px rgba(31, 61, 20, 0.35);
	transition: background 200ms ease, transform 180ms var(--gkpc-feat-ease), box-shadow 200ms ease;
}

.gk-product-card-featured__cta:hover {
	background: var(--gkpc-feat-emerald);
	color: #ffffff;
	transform: translateY(-1px);
	box-shadow: 0 12px 32px -6px rgba(0, 150, 104, 0.45);
}

.gk-product-card-featured__cta:focus-visible {
	outline: 2px solid var(--gkpc-feat-brand);
	outline-offset: 3px;
}

.gk-product-card-featured__cta svg {
	flex-shrink: 0;
}

.gk-product-card-featured__cta--disabled,
.gk-product-card-featured__cta[disabled] {
	background: #E5E7EB;
	color: var(--gkpc-feat-text-faint);
	cursor: not-allowed;
	box-shadow: none;
	pointer-events: none;
}

.gk-product-card-featured__cta--disabled:hover {
	background: #E5E7EB;
	color: var(--gkpc-feat-text-faint);
	transform: none;
	box-shadow: none;
}

/* ═══════════════════════════════════════════════════════════════
 * OUT-OF-STOCK STATE
 * ═══════════════════════════════════════════════════════════════ */
.gk-product-card-featured--out-of-stock .gk-product-card-featured__image {
	filter: grayscale(0.3);
	opacity: 0.85;
}

/* ═══════════════════════════════════════════════════════════════
 * SCOPE OVERRIDE — gk-archive-v5-body cascade hardening
 * (default tile uses !important on body padding 18px — featured must
 *  beat that by SCOPING own selectors with body scope + own naming).
 * ═══════════════════════════════════════════════════════════════ */
body.gk-archive-v5-body .gk-product-card-featured {
	height: 100%;
	min-height: 480px;
}

body.gk-archive-v5-body .gk-product-card-featured__content {
	padding: 40px clamp(28px, 4vw, 48px) !important;
}

body.gk-archive-v5-body .gk-product-card-featured__media {
	margin: 0 !important;
	border: 0 !important;
	border-radius: 0 !important;
}

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

/* Tablet — stack vertical pod 1024px (z grid-col 1/-1 z shop-archive.css) */
@media (max-width: 1024px) {
	.gk-product-card-featured {
		grid-template-columns: 1fr;
		min-height: 0;
	}

	/* Force visual top-down on stack — image first regardless of variant */
	.gk-product-card-featured--a .gk-product-card-featured__media,
	.gk-product-card-featured--b .gk-product-card-featured__media {
		order: 1;
	}
	.gk-product-card-featured--a .gk-product-card-featured__content,
	.gk-product-card-featured--b .gk-product-card-featured__content {
		order: 2;
	}

	.gk-product-card-featured__media {
		min-height: 0;
		aspect-ratio: 16 / 9;
		max-height: 360px;
	}

	body.gk-archive-v5-body .gk-product-card-featured__content {
		padding: 28px clamp(20px, 5vw, 32px) !important;
		gap: 14px;
	}

	.gk-product-card-featured__title {
		font-size: clamp(24px, 4.5vw, 30px);
	}

	.gk-product-card-featured__price {
		font-size: 28px;
	}

	.gk-product-card-featured__price del,
	.gk-product-card-featured__price del .woocommerce-Price-amount {
		font-size: 16px;
	}
}

/* Mobile — tighter padding + smaller title */
@media (max-width: 640px) {
	.gk-product-card-featured {
		min-height: 0;
	}

	.gk-product-card-featured__media {
		aspect-ratio: 4 / 3;
		max-height: 280px;
	}

	body.gk-archive-v5-body .gk-product-card-featured__content {
		padding: 24px 20px !important;
		gap: 12px;
	}

	.gk-product-card-featured__title {
		font-size: 22px;
	}

	.gk-product-card-featured__excerpt {
		font-size: 14px;
		-webkit-line-clamp: 2;
	}

	.gk-product-card-featured__price {
		font-size: 24px;
	}

	.gk-product-card-featured__price del,
	.gk-product-card-featured__price del .woocommerce-Price-amount {
		font-size: 15px;
	}

	.gk-product-card-featured__ribbon {
		top: 14px;
		left: 14px;
		padding: 6px 12px;
		font-size: 10px;
	}

	.gk-product-card-featured__heart {
		top: 50px;
		left: 14px;
	}

	.gk-product-card-featured__heart-btn,
	.gk-product-card-featured__heart .yith-wcwl-add-to-wishlist {
		width: 40px;
		height: 40px;
	}

	.gk-product-card-featured__badges {
		top: 14px;
		right: 14px;
		gap: 6px;
	}

	.gk-product-card-featured__badge {
		padding: 5px 10px;
		font-size: 10px;
	}

	.gk-product-card-featured__cta {
		max-width: 100%;
		padding: 12px 20px;
		font-size: 14px;
	}
}
