/* FY Kit effects: layers drawn into a Cover or Group block. Themes can restyle
 * through the classes; colours come from the block's Effect settings. */
:where(.has-fyek-fx) { position: relative; isolation: isolate; }
.has-fyek-fx > .fyek-fx-layer,
.has-fyek-fx > .fyek-fx-node { position: absolute !important; left: 0; top: 0; display: block; max-width: none !important; margin: 0 !important; padding: 0 !important; pointer-events: none; }
.has-fyek-fx > .fyek-fx-layer--under,
.has-fyek-fx > .fyek-fx-layer--over { inset: 0; width: 100% !important; height: 100% !important; }
.has-fyek-fx > .fyek-fx-layer--under,
.has-fyek-fx > .fyek-fx-layer--photo { z-index: 1; }
.has-fyek-fx > .fyek-fx-layer--over,
.has-fyek-fx > .fyek-fx-layer--on-img { z-index: 3; }
/* A veil and candlelight lie on the photo itself, over it (and under any words placed over it). */
.has-fyek-fx.fyek-fx-veil > .fyek-fx-layer--photo,
.has-fyek-fx.fyek-fx-candles > .fyek-fx-layer--photo { z-index: 3; }

/* Words stay above the layers. In a Cover the inner container does this already. */
.wp-block-cover.has-fyek-fx > .wp-block-cover__inner-container { position: relative; z-index: 2; }
:where(.wp-block-group.has-fyek-fx) > :where(:not(.fyek-fx-layer):not(.fyek-fx-node)) { position: relative; z-index: 2; }

/* Pointer hints. */
.has-fyek-fx.is-fyek-fx-hit { cursor: pointer; }
.has-fyek-fx.fyek-fx-toys.is-fyek-fx-hit { cursor: grab; }
.has-fyek-fx.is-fyek-fx-holding { cursor: grabbing; user-select: none; }

/* Speed streaks: the first heading leans into the wind. */
.has-fyek-fx[data-fyek-fx-lean] :is(h1, h2):first-of-type { transform: skewX(var(--fyek-fx-lean, 0deg)); transform-origin: 0 100%; transition: transform .25s ease-out; }

/* Stage spotlight: the photo dimmed, a full colour copy shows through the light. */
.has-fyek-fx[data-fyek-fx-dim="dark"] [data-fyek-fx-dimmed] { filter: brightness(.42) saturate(.7); }
.has-fyek-fx[data-fyek-fx-dim="grey"] [data-fyek-fx-dimmed] { filter: grayscale(1) brightness(.62) contrast(1.1); }
.has-fyek-fx[data-fyek-fx-dim="riso"] { background-color: var(--fyek-fx-ink, #e5398f) !important; }
.has-fyek-fx[data-fyek-fx-dim="riso"] [data-fyek-fx-dimmed] { filter: grayscale(1) contrast(1.35) brightness(.98); mix-blend-mode: screen; }
.has-fyek-fx > .fyek-fx-spot { z-index: 1; object-fit: cover; background-repeat: no-repeat; filter: saturate(1.3) brightness(1.15) contrast(1.05); -webkit-mask: radial-gradient(circle var(--fyek-fx-r, 240px) at var(--fyek-fx-x, 70%) var(--fyek-fx-y, 34%), #000 0, #000 38%, rgba(0, 0, 0, .55) 64%, transparent 100%); mask: radial-gradient(circle var(--fyek-fx-r, 240px) at var(--fyek-fx-x, 70%) var(--fyek-fx-y, 34%), #000 0, #000 38%, rgba(0, 0, 0, .55) 64%, transparent 100%); }
.has-fyek-fx > .fyek-fx-beam { inset: 0; z-index: 1; width: 100%; height: 100%; background: linear-gradient(180deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, .13) 75%, rgba(255, 255, 255, .03)); mix-blend-mode: screen; }

@media (prefers-reduced-motion: reduce) {
	.has-fyek-fx[data-fyek-fx-lean] :is(h1, h2):first-of-type { transform: none; }
}

/* ---------- Label numbers (factsheet): a nutrition-label card in the block ---------- */
.has-fyek-factsheet { position: relative; }
.fyek-factsheet {
	--fyek-fs-tint: var(--fyek-accent, #c2562d);
	--fyek-fs-on-tint: #fff;
	--fyek-fs-rx: 0deg;
	--fyek-fs-ry: 0deg;
	position: absolute;
	z-index: 3;
	left: var(--fyek-fs-x, 74%);
	top: var(--fyek-fs-y, 52%);
	width: min(var(--fyek-fs-w, 320px), 42vw);
	box-sizing: border-box;
	padding: 14px 18px 16px;
	background: #fff;
	color: #141414;
	border: 3px solid #141414;
	border-radius: 4px;
	box-shadow: 10px 12px 0 rgba(20, 20, 20, .9);
	font-family: inherit;
	transform: translate(-50%, -50%) perspective(900px) rotate(var(--fyek-fs-tilt, -4deg)) rotateX(var(--fyek-fs-rx)) rotateY(var(--fyek-fs-ry));
	transition: box-shadow .3s ease;
	pointer-events: none;
}
/* The shared rule for effect nodes pins them to the corner without padding; the card sits where it is told. */
.has-fyek-fx > .fyek-fx-node.fyek-factsheet { position: absolute !important; left: var(--fyek-fs-x, 74%); top: var(--fyek-fs-y, 52%); padding: 14px 18px 16px !important; }
.fyek-factsheet.is-pop { animation: fyek-fs-pop .5s cubic-bezier(.2, 1.6, .4, 1); }
@keyframes fyek-fs-pop { 0% { scale: .96; } 60% { scale: 1.02; } 100% { scale: 1; } }
.fyek-factsheet p { margin: 0; }
.fyek-factsheet__head {
	padding-bottom: 6px;
	border-bottom: 9px solid #141414;
	font-size: clamp(1.25rem, 2vw, 1.75rem);
	font-weight: 900;
	line-height: 1;
	letter-spacing: -.02em;
}
.fyek-factsheet__serve { padding: 6px 0 7px; border-bottom: 4px solid #141414; font-size: .8125rem; font-weight: 600; }
.fyek-factsheet__row {
	display: grid;
	grid-template-columns: 1fr auto;
	align-items: baseline;
	column-gap: 12px;
	padding: 8px 0 9px;
	border-bottom: 1px solid #141414;
}
.fyek-factsheet__name { font-size: .875rem; font-weight: 700; }
.fyek-factsheet__value { white-space: nowrap; font-variant-numeric: tabular-nums; }
.fyek-factsheet__value b { font-size: 1.375rem; font-weight: 900; letter-spacing: -.02em; }
.fyek-factsheet__value small { margin-left: 3px; font-size: .8125rem; font-weight: 700; }
.fyek-factsheet__row.is-lead { padding: 10px 0 12px; border-bottom-width: 4px; }
.fyek-factsheet__row.is-lead .fyek-factsheet__name { font-size: 1rem; }
.fyek-factsheet__row.is-lead .fyek-factsheet__value b { font-size: clamp(2.75rem, 5vw, 4rem); line-height: .9; }
.fyek-factsheet__row.is-lead .fyek-factsheet__value small { font-size: 1.125rem; }
.fyek-factsheet__bar { grid-column: 1 / -1; display: block; height: 10px; margin-top: 7px; background: rgba(20, 20, 20, .08); border-radius: 2px; overflow: hidden; }
.fyek-factsheet__bar i { display: block; height: 100%; background: var(--fyek-fs-tint); transform-origin: left center; transform: scaleX(0); }
.fyek-factsheet__row.is-lead .fyek-factsheet__bar { height: 14px; }
.fyek-factsheet__note { padding-top: 7px; font-size: .6875rem; line-height: 1.35; color: #444; }
.fyek-factsheet.is-tinted { box-shadow: 10px 12px 0 var(--fyek-fs-tint); }
@media (max-width: 781px) {
	/* On a phone the card follows the text instead of floating over the photo, packed with it in the middle of the block. */
	.has-fyek-factsheet { flex-wrap: wrap; align-content: center; }
	.has-fyek-fx > .fyek-fx-node.fyek-factsheet {
		position: relative !important;
		left: auto;
		top: auto;
		order: 2;
		width: min(calc(100% - 24px), 340px);
		margin: 28px auto 12px !important;
		transform: rotate(calc(var(--fyek-fs-tilt, -4deg) / 2));
	}
}
@media (prefers-reduced-motion: reduce) {
	.fyek-factsheet.is-pop { animation: none; }
}

/* Hair shine */
.fyek-shine { position: absolute; z-index: 1; overflow: hidden; pointer-events: none; }
.fyek-shine__gloss, .fyek-shine__glow { position: absolute; inset: 0; }
.fyek-shine__gloss { mix-blend-mode: color-dodge; }
.fyek-shine__glow { mix-blend-mode: overlay; }
.fyek-shine:not(.is-masked) .fyek-shine__glow { opacity: .6; }
