/*
 * The Gift It bow (inc/seasons.php): a bow on the Gift It buttons, which wiggles on hover. Loaded only
 * on the dates in Theme Settings > Gift It Bow, so it costs nothing the rest of the year. The bow is
 * absolutely positioned, so nothing on the page moves.
 */

/* ── A bow on the Gift It buttons ── */
.sc-gift-bow .sc-btn-gift {
	position: relative;
	overflow: visible;
}

.sc-gift-bow .sc-btn-gift::after {
	content: "";
	position: absolute;
	/* The knot (51.4% across, 43% down the drawing) sits on the button's top border, close to its
	   right corner: 33px from the right edge here, 18px on a phone (where the corner's curve starts,
	   half a pixel below the line). The loops stand above the line and lean out to the right; the
	   tails hang down over the button, clear of its words. 66 x 57 here; 56 x 48 on a phone, below. */
	top: -24px;
	right: 1px;
	width: 66px;
	height: 57px;
	/* A flat, thin ribbon bow, drawn for the site (5 December 2026): two open loops showing the
	   ribbon's darker inside, a small knot, two long curved tails with V-cut ends, a dark red
	   outline, the whole bow tilted about 20 degrees to the right, leaning away from the words. */
	background: url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%22-4 -6 88 76%22%3E%3Cg transform=%22rotate(20 40 30)%22 stroke=%22%238E0A22%22 stroke-width=%221.4%22 stroke-linejoin=%22round%22 stroke-linecap=%22round%22%3E%3Cpath d=%22M37.5 30 C35 39 29 47 21 56 L25.6 54.2 L26.4 59.8 C33 51 38.6 42 41.2 31 Z%22 fill=%22%23FE415F%22/%3E%3Cpath d=%22M42.5 30 C45 39 51 47 59 56 L54.4 54.2 L53.6 59.8 C47 51 41.4 42 38.8 31 Z%22 fill=%22%23FE415F%22/%3E%3Cpath d=%22M37 24 C30 12 14 6 9 13 C5 19 12 28 37 29 L36 27.5 C17 25.5 11 20 14 16 C18 12 31 17 36 25.5 Z%22 fill=%22%23C9233F%22/%3E%3Cpath d=%22M37 24 C30 12 14 6 9 13 C7.6 15.2 7.6 17.6 9.4 19.8 C10.6 18.2 12 17 14 16 C18 12 31 17 36 25.5 Z%22 fill=%22%23FE415F%22/%3E%3Cpath d=%22M43 24 C50 12 66 6 71 13 C75 19 68 28 43 29 L44 27.5 C63 25.5 69 20 66 16 C62 12 49 17 44 25.5 Z%22 fill=%22%23C9233F%22/%3E%3Cpath d=%22M43 24 C50 12 66 6 71 13 C72.4 15.2 72.4 17.6 70.6 19.8 C69.4 18.2 68 17 66 16 C62 12 49 17 44 25.5 Z%22 fill=%22%23FE415F%22/%3E%3Crect x=%2236.2%22 y=%2222.2%22 width=%227.6%22 height=%228.6%22 rx=%223%22 fill=%22%23FE415F%22/%3E%3Cpath d=%22M38 24.5 C39.3 23.8 40.7 23.8 42 24.5%22 fill=%22none%22 stroke=%22%23C9233F%22 stroke-width=%221.1%22/%3E%3C/g%3E%3C/svg%3E") center / contain no-repeat;
	/* It wiggles about the knot, as if tied there. */
	transform-origin: 51.4% 43%;
	pointer-events: none;
}

@media (max-width: 767.98px) {
	.sc-gift-bow .sc-btn-gift::after {
		top: -20px;
		right: -9px;
		width: 56px;
		height: 48px;
	}
}

.sc-gift-bow .sc-btn-gift:is(:hover, :focus-visible)::after {
	animation: sc-bow-wiggle .6s ease-in-out;
}

@keyframes sc-bow-wiggle {
	0%, 100% { transform: rotate(0); }
	25% { transform: rotate(-12deg); }
	50% { transform: rotate(10deg); }
	75% { transform: rotate(-6deg); }
}

/* Anyone who has asked their device for less motion (on an iPhone: Settings > Accessibility > Motion >
   Reduce Motion) gets lights that glow without twinkling, a bauble that stays put and a still bow. */

/* Anyone who has asked their device for less motion (on an iPhone: Settings > Accessibility > Motion >
   Reduce Motion) gets a still bow. */
@media (prefers-reduced-motion: reduce) {
	.sc-gift-bow .sc-btn-gift:is(:hover, :focus-visible)::after {
		animation: none;
	}
}
