/**
 * FAME Campaign Calendar – frontend styles.
 * Everything is scoped under .fame-cc so nothing leaks into the theme or WooCommerce.
 * Colours and fonts arrive as CSS custom properties from the campaign settings.
 */

.fame-cc {
	--fcc-primary: #DE9DAC;
	--fcc-primary-deep: #BA8491;
	--fcc-powder: #F8E5EC;
	--fcc-light: #F2CBD9;
	--fcc-gold: #D4AF37;
	--fcc-gold-deep: #AA8C2C;
	--fcc-champagne: #E8D5A8;
	--fcc-cream: #FFF9F5;
	--fcc-white: #FFFFFF;
	--fcc-text: #8A3A52;
	--fcc-font-heading: inherit;
	--fcc-font-body: inherit;
	box-sizing: border-box;
	font-family: var(--fcc-font-body);
	line-height: 1.5;
}

.fame-cc *,
.fame-cc *::before,
.fame-cc *::after {
	box-sizing: border-box;
}

.fame-cc[hidden],
.fame-cc [hidden] {
	display: none !important;
}

.fame-cc-defs {
	position: absolute;
	width: 0;
	height: 0;
	overflow: hidden;
}

/* ---------- Calendar ---------- */

.fame-cc-calendar {
	position: relative;
	isolation: isolate;
	overflow: hidden;
	margin: 24px auto 32px;
	padding: clamp(30px, 5vw, 64px) clamp(14px, 4vw, 52px) clamp(40px, 5vw, 68px);
	border-radius: 28px;
	color: var(--fcc-text);
	text-align: center;
	background:
		var(--fcc-bg-image, linear-gradient(transparent, transparent)) center / cover no-repeat,
		radial-gradient(110% 70% at 50% 0%, var(--fcc-cream) 0%, rgba(255, 255, 255, 0) 62%),
		linear-gradient(165deg, var(--fcc-powder) 0%, var(--fcc-light) 58%, var(--fcc-primary) 135%);
	box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .65), 0 26px 60px -34px rgba(138, 58, 82, .5);
}

.fame-cc-calendar::before {
	content: "";
	position: absolute;
	inset: 10px;
	z-index: 0;
	border: 1px solid var(--fcc-gold);
	border-radius: 20px;
	opacity: .55;
	pointer-events: none;
}

/* Discreet golden stars and sparkles. */
.fame-cc-sparkles {
	position: absolute;
	inset: 0;
	z-index: 0;
	pointer-events: none;
	opacity: .55;
	background-image:
		url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cg fill='%23D4AF37'%3E%3Cpath d='M30 20c.6 4 3 6.400 7 7-4 .600-6.400 3-7 7-.600-4-3-6.400-7-7 4-.600 6.400-3 7-7z' opacity='.7'/%3E%3Cpath d='M170 60c.4 2.600 2 4.200 4.600 4.600-2.600.400-4.200 2-4.600 4.600-.400-2.600-2-4.200-4.600-4.600 2.600-.400 4.200-2 4.600-4.600z' opacity='.6'/%3E%3Cpath d='M95 150c.5 3.300 2.500 5.300 5.800 5.800-3.300.500-5.300 2.500-5.800 5.800-.500-3.300-2.500-5.300-5.800-5.800 3.300-.500 5.300-2.500 5.800-5.800z' opacity='.5'/%3E%3Ccircle cx='200' cy='180' r='1.600' opacity='.6'/%3E%3Ccircle cx='60' cy='110' r='1.200' opacity='.5'/%3E%3Ccircle cx='130' cy='25' r='1.400' opacity='.55'/%3E%3Ccircle cx='20' cy='190' r='1.300' opacity='.5'/%3E%3C/g%3E%3C/svg%3E");
	background-size: 220px 220px;
	animation: fcc-twinkle 6s ease-in-out infinite;
}

.fame-cc-head {
	position: relative;
	z-index: 1;
	max-width: 720px;
	margin: 0 auto;
}

.fame-cc-title {
	margin: 0;
	padding: 0;
	font-family: var(--fcc-font-heading);
	font-size: clamp(30px, 5.4vw, 58px);
	font-weight: 700;
	line-height: 1.1;
	letter-spacing: .14em;
	text-transform: uppercase;
	color: var(--fcc-text);
}

.fame-cc-title::after {
	content: "";
	display: block;
	width: 96px;
	height: 2px;
	margin: 16px auto 0;
	background: linear-gradient(90deg, rgba(255, 255, 255, 0), var(--fcc-gold), rgba(255, 255, 255, 0));
}

.fame-cc-subtitle {
	margin: 14px 0 0;
	font-family: var(--fcc-font-heading);
	font-size: clamp(17px, 2.4vw, 24px);
	font-style: italic;
	color: var(--fcc-text);
}

.fame-cc-description {
	margin: 10px auto 0;
	max-width: 560px;
	font-size: clamp(14px, 1.6vw, 16px);
	color: var(--fcc-text);
}

.fame-cc-description p {
	margin: 0 0 6px;
}

.fame-cc-countdown {
	display: inline-flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 6px 10px;
	margin-top: 18px;
	padding: 9px 20px;
	border: 1px solid var(--fcc-gold);
	border-radius: 999px;
	background: rgba(255, 255, 255, .72);
	font-size: 14px;
	color: var(--fcc-text);
}

.fame-cc-countdown-time,
.fame-cc-card-countdown-time,
.fame-cc-banner-time {
	font-weight: 700;
	font-variant-numeric: tabular-nums;
	letter-spacing: .04em;
}

.fame-cc-countdown-box {
	text-align: center;
}

/* ---------- Grid of gifts ---------- */

.fame-cc-grid {
	position: relative;
	z-index: 1;
	display: grid;
	grid-template-columns: repeat(var(--fcc-cols-d, 6), minmax(0, 1fr));
	gap: clamp(18px, 2.6vw, 34px) clamp(10px, 2vw, 26px);
	max-width: 1040px;
	margin: clamp(26px, 4vw, 44px) auto 0;
	padding: 0;
	list-style: none;
}

@media (max-width: 1024px) {
	.fame-cc-grid {
		grid-template-columns: repeat(var(--fcc-cols-t, 4), minmax(0, 1fr));
	}
}

@media (max-width: 600px) {
	.fame-cc-grid {
		grid-template-columns: repeat(var(--fcc-cols-m, 3), minmax(0, 1fr));
	}

	.fame-cc-calendar {
		border-radius: 20px;
	}
}

.fame-cc-door {
	position: relative;
	margin: 0;
	padding: 0;
	list-style: none;
	container-type: inline-size;
}

.fame-cc-door::before,
.fame-cc-door::marker {
	content: none;
}

.fame-cc-gift {
	position: relative;
	display: block;
	width: 100%;
	margin: 0;
	padding: 0;
	aspect-ratio: 120 / 132;
	border: 0;
	border-radius: 14px;
	background: none;
	box-shadow: none;
	color: inherit;
	font: inherit;
	line-height: 1;
	cursor: pointer;
	-webkit-tap-highlight-color: transparent;
	transition: transform .3s ease, filter .3s ease, opacity .3s ease;
}

.fame-cc-gift:hover,
.fame-cc-gift:focus {
	background: none;
	box-shadow: none;
	color: inherit;
}

.fame-cc-gift:focus-visible {
	outline: 3px solid var(--fcc-text);
	outline-offset: 5px;
}

.fame-cc-gift-art,
.fame-cc-gift-image {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	overflow: visible;
	filter: drop-shadow(0 9px 9px rgba(138, 58, 82, .2));
}

.fame-cc-gift-image {
	object-fit: contain;
}

.fame-cc-l-top,
.fame-cc-l-bow,
.fame-cc-l-glow {
	transform-box: view-box;
	transition: transform .5s ease, opacity .5s ease;
}

.fame-cc-l-top {
	transform-origin: 20px 58px;
}

.fame-cc-l-bow {
	transform-origin: 60px 37px;
}

.fame-cc-l-glow {
	transform-origin: 60px 56px;
	opacity: 0;
}

.fame-cc-num {
	position: absolute;
	left: 50%;
	top: 68.2%;
	transform: translate(-50%, -50%);
	font-family: var(--fcc-font-heading);
	font-size: clamp(14px, 2.4vw, 25px);
	font-size: clamp(13px, 20cqw, 30px);
	font-weight: 700;
	line-height: 1;
	font-variant-numeric: tabular-nums;
	color: var(--fcc-text);
	pointer-events: none;
}

.fame-cc-num.is-wide {
	font-size: clamp(12px, 2vw, 21px);
	font-size: clamp(11px, 16cqw, 24px);
	letter-spacing: -.02em;
}

.fame-cc-gift.has-image .fame-cc-num {
	top: 62%;
	width: 31%;
	aspect-ratio: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	border: 1px solid var(--fcc-gold);
	border-radius: 50%;
	background: var(--fcc-cream);
}

.fame-cc-lock {
	position: absolute;
	right: 9%;
	top: 44%;
	display: none;
	width: 21%;
	aspect-ratio: 1;
	align-items: center;
	justify-content: center;
	border: 1px solid var(--fcc-gold);
	border-radius: 50%;
	background: var(--fcc-cream);
	box-shadow: 0 2px 6px rgba(138, 58, 82, .2);
	pointer-events: none;
}

.fame-cc-lock svg {
	width: 58%;
	height: 58%;
	fill: var(--fcc-text);
	opacity: .8;
}

.fame-cc-spark {
	position: absolute;
	left: 6%;
	top: 30%;
	width: 17%;
	aspect-ratio: 1;
	pointer-events: none;
	animation: fcc-spark 2.8s ease-in-out infinite;
}

.fame-cc-spark svg {
	width: 100%;
	height: 100%;
	fill: var(--fcc-gold);
	filter: drop-shadow(0 0 3px rgba(255, 255, 255, .9));
}

.fame-cc-label {
	position: absolute;
	left: 50%;
	bottom: -9%;
	transform: translateX(-50%);
	padding: 4px 11px;
	border-radius: 999px;
	font-size: clamp(10px, 1.2vw, 12px);
	font-weight: 700;
	letter-spacing: .05em;
	line-height: 1.2;
	white-space: nowrap;
	pointer-events: none;
}

.fame-cc-label:empty {
	display: none;
}

/* Status: waiting for the server. */
.fame-cc-door.is-pending .fame-cc-gift {
	cursor: default;
}

/* Status: locked (future day). */
.fame-cc-door.is-locked .fame-cc-lock {
	display: flex;
}

.fame-cc-door.is-locked .fame-cc-gift:hover {
	transform: translateY(-3px);
}

/* Status: active (today). */
.fame-cc-door.is-active {
	z-index: 2;
}

.fame-cc-door.is-active .fame-cc-gift {
	transform: scale(1.07);
}

.fame-cc-door.is-active .fame-cc-gift:hover {
	transform: scale(1.11);
}

.fame-cc-door.is-active .fame-cc-l-glow {
	opacity: 1;
	animation: fcc-glow 2.6s ease-in-out infinite;
}

.fame-cc-door.is-active .fame-cc-l-bow {
	animation: fcc-bow 3.2s ease-in-out infinite;
}

.fame-cc-door.is-active .fame-cc-label,
.fame-cc-door.is-exhausted .fame-cc-label {
	background: var(--fcc-text);
	color: #fff;
	box-shadow: 0 0 0 1px var(--fcc-gold), 0 6px 14px -6px rgba(138, 58, 82, .7);
}

/* Status: exhausted (today's gifts are gone). */
.fame-cc-door.is-exhausted .fame-cc-gift-art,
.fame-cc-door.is-exhausted .fame-cc-gift-image {
	filter: grayscale(.35) drop-shadow(0 9px 9px rgba(138, 58, 82, .2));
}

.fame-cc-door.is-exhausted .fame-cc-l-top,
.fame-cc-door.is-finished .fame-cc-l-top,
.fame-cc-door.is-open .fame-cc-l-top {
	transform: translate(-7px, -20px) rotate(-13deg);
}

/* Status: finished (past day). */
.fame-cc-door.is-finished .fame-cc-gift-art,
.fame-cc-door.is-finished .fame-cc-gift-image {
	filter: grayscale(.6) drop-shadow(0 6px 6px rgba(138, 58, 82, .12));
	opacity: .7;
}

.fame-cc-door.is-finished .fame-cc-num {
	opacity: .75;
}

.fame-cc-door.is-finished .fame-cc-label {
	background: rgba(255, 255, 255, .85);
	color: var(--fcc-text);
	box-shadow: 0 0 0 1px var(--fcc-light);
	font-weight: 600;
}

/* Special days (for example 6 and 24 December). */
.fame-cc-door.is-special .fame-cc-gift::after {
	content: "";
	position: absolute;
	inset: -7% -9% -5%;
	z-index: -1;
	border: 1px dashed var(--fcc-gold);
	border-radius: 18px;
	background: radial-gradient(closest-side, rgba(255, 255, 255, .7), rgba(255, 255, 255, 0));
	pointer-events: none;
}

/* Opening animation (about one second). */
.fame-cc-door.is-opening {
	z-index: 5;
}

.fame-cc-door.is-opening .fame-cc-gift {
	animation: fcc-pop 1s ease forwards;
}

.fame-cc-door.is-opening .fame-cc-l-top {
	animation: fcc-lid 1s cubic-bezier(.3, .7, .3, 1) forwards;
}

.fame-cc-door.is-opening .fame-cc-l-bow {
	animation: fcc-untie 1s ease forwards;
}

.fame-cc-door.is-opening .fame-cc-l-glow {
	animation: fcc-burst 1s ease-out forwards;
}

.fame-cc-door.is-open .fame-cc-l-bow {
	opacity: 0;
}

.fame-cc-confetti {
	position: absolute;
	left: 50%;
	top: 40%;
	width: 6px;
	height: 10px;
	border-radius: 2px;
	background: linear-gradient(135deg, var(--fcc-champagne), var(--fcc-gold));
	opacity: 0;
	pointer-events: none;
	animation: fcc-confetti .75s ease-out forwards;
}

.fame-cc-confetti.is-round {
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background: var(--fcc-gold);
}

/* Message on a locked door. */
.fame-cc-bubble {
	position: absolute;
	left: 50%;
	bottom: calc(100% - 22%);
	z-index: 6;
	width: max-content;
	max-width: min(230px, 62vw);
	padding: 9px 13px;
	border: 1px solid var(--fcc-gold);
	border-radius: 12px;
	background: var(--fcc-cream);
	box-shadow: 0 12px 26px -12px rgba(138, 58, 82, .6);
	color: var(--fcc-text);
	font-size: 13px;
	font-weight: 600;
	line-height: 1.35;
	opacity: 0;
	transform: translate(-50%, 6px);
	transition: opacity .25s ease, transform .25s ease;
	pointer-events: none;
}

.fame-cc-door.has-bubble {
	z-index: 6;
}

.fame-cc-door.has-bubble .fame-cc-bubble {
	opacity: 1;
	transform: translate(-50%, 0);
}

.fame-cc-door.is-shake .fame-cc-gift {
	animation: fcc-shake .5s ease;
}

.fame-cc-live {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
}

.fame-cc-noscript {
	position: relative;
	z-index: 1;
	margin: 18px 0 0;
	font-size: 14px;
}

/* ---------- Pop-up ---------- */

html.fame-cc-modal-open {
	overflow: hidden;
}

.fame-cc-modal {
	position: fixed;
	inset: 0;
	z-index: 999999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
	opacity: 0;
	visibility: hidden;
	transition: opacity .25s ease, visibility .25s ease;
}

.fame-cc-modal.is-visible {
	opacity: 1;
	visibility: visible;
}

.fame-cc-modal-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(74, 28, 42, .58);
	-webkit-backdrop-filter: blur(3px);
	backdrop-filter: blur(3px);
}

.fame-cc-modal-box {
	position: relative;
	width: min(500px, 100%);
	max-height: calc(100vh - 32px);
	max-height: calc(100dvh - 32px);
	overflow: auto;
	padding: 38px 28px 28px;
	border-radius: 24px;
	outline: none;
	color: var(--fcc-text);
	text-align: center;
	background: linear-gradient(172deg, var(--fcc-cream) 0%, var(--fcc-powder) 48%, var(--fcc-light) 100%);
	box-shadow: 0 0 0 1px var(--fcc-gold), 0 0 0 7px rgba(255, 255, 255, .6), 0 0 0 8px var(--fcc-champagne), 0 34px 80px -22px rgba(74, 28, 42, .7);
	transform: translateY(16px) scale(.97);
	transition: transform .32s cubic-bezier(.2, .9, .3, 1.15);
}

.fame-cc-modal.is-visible .fame-cc-modal-box {
	transform: none;
}

.fame-cc-modal-close {
	position: absolute;
	right: 12px;
	top: 10px;
	width: 40px;
	height: 40px;
	padding: 0;
	border: 1px solid var(--fcc-light);
	border-radius: 50%;
	background: rgba(255, 255, 255, .8);
	color: var(--fcc-text);
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
}

.fame-cc-modal-close:hover,
.fame-cc-modal-close:focus {
	background: #fff;
	color: var(--fcc-text);
}

.fame-cc-modal-close:focus-visible,
.fame-cc-cta:focus-visible,
.fame-cc-coupon-copy:focus-visible,
.fame-cc-widget button:focus-visible,
.fame-cc-banner-close:focus-visible,
.fame-cc-terms summary:focus-visible {
	outline: 3px solid var(--fcc-text);
	outline-offset: 3px;
}

.fame-cc-eyebrow {
	margin: 0 0 4px;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: .2em;
	text-transform: uppercase;
	color: var(--fcc-text);
}

.fame-cc-date {
	margin: 0 0 10px;
	font-size: 13px;
	color: var(--fcc-text);
	opacity: .85;
}

.fame-cc-card-title {
	margin: 0 0 14px;
	padding: 0;
	font-family: var(--fcc-font-heading);
	font-size: clamp(22px, 4vw, 30px);
	font-weight: 700;
	line-height: 1.2;
	color: var(--fcc-text);
}

.fame-cc-card-title::after {
	content: "";
	display: block;
	width: 64px;
	height: 2px;
	margin: 12px auto 0;
	background: linear-gradient(90deg, rgba(255, 255, 255, 0), var(--fcc-gold), rgba(255, 255, 255, 0));
}

.fame-cc-card-number {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 72px;
	height: 72px;
	margin: 0 auto 14px;
	border: 1px solid var(--fcc-gold);
	border-radius: 50%;
	background: var(--fcc-cream);
	font-family: var(--fcc-font-heading);
	font-size: 30px;
	font-weight: 700;
}

.fame-cc-card-message {
	margin: 0;
	font-size: 17px;
	font-weight: 600;
}

.fame-cc-card-image {
	position: relative;
	margin: 0 0 16px;
}

.fame-cc-card-image img {
	display: block;
	width: 100%;
	height: auto;
	max-height: 280px;
	object-fit: cover;
	border-radius: 16px;
	box-shadow: 0 0 0 1px var(--fcc-gold), 0 14px 30px -18px rgba(138, 58, 82, .7);
}

.fame-cc-value {
	position: absolute;
	right: 10px;
	top: 10px;
	padding: 6px 13px;
	border-radius: 999px;
	background: linear-gradient(135deg, var(--fcc-champagne), var(--fcc-gold));
	color: #3D2B00;
	font-size: 14px;
	font-weight: 700;
	box-shadow: 0 6px 14px -6px rgba(0, 0, 0, .4);
}

.fame-cc-value.is-inline {
	position: static;
	display: inline-block;
	margin: 0 0 14px;
}

.fame-cc-card-desc {
	margin: 0 0 12px;
	font-size: 16px;
}

.fame-cc-card-desc p {
	margin: 0 0 8px;
}

.fame-cc-min {
	margin: 0 0 12px;
	font-size: 14px;
	font-weight: 600;
}

.fame-cc-note {
	margin: 0 0 14px;
	padding: 10px 14px;
	border-radius: 12px;
	background: rgba(255, 255, 255, .75);
	box-shadow: inset 0 0 0 1px var(--fcc-gold);
	font-size: 15px;
	font-weight: 700;
}

.fame-cc-note.is-past {
	box-shadow: inset 0 0 0 1px var(--fcc-light);
	font-weight: 600;
}

.fame-cc-coupon {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 8px 10px;
	margin: 0 0 14px;
	padding: 12px;
	border: 1px dashed var(--fcc-gold);
	border-radius: 14px;
	background: rgba(255, 255, 255, .7);
	font-size: 14px;
}

.fame-cc-coupon-code {
	padding: 4px 10px;
	border-radius: 8px;
	background: var(--fcc-cream);
	color: var(--fcc-text);
	font-size: 17px;
	font-weight: 700;
	letter-spacing: .08em;
}

.fame-cc-coupon-copy {
	padding: 6px 12px;
	border: 1px solid var(--fcc-text);
	border-radius: 999px;
	background: transparent;
	color: var(--fcc-text);
	font-size: 13px;
	font-weight: 600;
	cursor: pointer;
}

.fame-cc-card-countdown {
	display: inline-flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 4px 8px;
	margin: 0 0 16px;
	padding: 8px 16px;
	border-radius: 999px;
	background: rgba(255, 255, 255, .78);
	box-shadow: inset 0 0 0 1px var(--fcc-champagne);
	font-size: 14px;
}

.fame-cc-cta,
.fame-cc-cta:visited {
	display: block;
	width: 100%;
	margin: 4px 0 0;
	padding: 15px 20px;
	border-radius: 999px;
	background: var(--fcc-text);
	box-shadow: 0 0 0 1px var(--fcc-gold), 0 14px 26px -14px rgba(74, 28, 42, .9);
	color: #fff;
	font-size: 15px;
	font-weight: 700;
	letter-spacing: .12em;
	text-align: center;
	text-decoration: none;
	text-transform: uppercase;
	transition: transform .2s ease, filter .2s ease;
}

.fame-cc-cta:hover,
.fame-cc-cta:focus {
	color: #fff;
	filter: brightness(1.12);
	transform: translateY(-1px);
	text-decoration: none;
}

.fame-cc-terms {
	margin: 14px 0 0;
	font-size: 13px;
	text-align: left;
}

.fame-cc-terms summary {
	cursor: pointer;
	font-weight: 600;
	text-align: center;
}

.fame-cc-terms-body {
	margin-top: 8px;
}

.fame-cc-terms-body p {
	margin: 0 0 6px;
}

/* [fame_campaign_today] */
.fame-cc-today {
	max-width: 520px;
	margin: 0 auto 24px;
}

.fame-cc-today .fame-cc-card {
	padding: 30px 26px 26px;
	border-radius: 24px;
	color: var(--fcc-text);
	text-align: center;
	background: linear-gradient(172deg, var(--fcc-cream) 0%, var(--fcc-powder) 48%, var(--fcc-light) 100%);
	box-shadow: 0 0 0 1px var(--fcc-gold), 0 20px 50px -30px rgba(74, 28, 42, .6);
}

/* ---------- Banner ---------- */

.fame-cc-banner {
	position: relative;
	z-index: 20;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 6px 14px;
	padding: 9px 48px 9px 16px;
	border-bottom: 1px solid var(--fcc-gold);
	background: linear-gradient(90deg, var(--fcc-light), var(--fcc-powder) 50%, var(--fcc-light));
	color: var(--fcc-text);
	font-size: 14px;
	font-weight: 600;
	line-height: 1.35;
	text-align: center;
}

.fame-cc-banner.is-inline {
	margin: 0 0 18px;
	border: 1px solid var(--fcc-gold);
	border-radius: 14px;
}

.fame-cc-banner-icon {
	display: inline-flex;
	flex: 0 0 26px;
}

.fame-cc-banner-icon .fame-cc-icon {
	width: 26px;
	height: 26px;
}

.fame-cc-banner-time {
	padding: 2px 10px;
	border-radius: 999px;
	background: rgba(255, 255, 255, .8);
}

.fame-cc-banner-link,
.fame-cc-banner-link:visited {
	color: var(--fcc-text);
	font-weight: 700;
	text-decoration: underline;
	text-underline-offset: 3px;
}

.fame-cc-banner-close {
	position: absolute;
	right: 8px;
	top: 50%;
	width: 32px;
	height: 32px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: transparent;
	color: var(--fcc-text);
	font-size: 22px;
	line-height: 1;
	cursor: pointer;
	transform: translateY(-50%);
}

/* ---------- Floating widget ---------- */

.fame-cc-widget {
	position: fixed;
	z-index: 1000; /* Above sticky headers, below side panels (cart, menu), cookie banners and chat launchers. */
	display: flex;
	align-items: flex-start;
}

.fame-cc-widget.is-bottom-left {
	left: var(--fcc-wx, 20px);
	bottom: var(--fcc-wy, 20px);
}

.fame-cc-widget.is-bottom-right {
	right: var(--fcc-wx, 20px);
	bottom: var(--fcc-wy, 20px);
}

.fame-cc-widget.is-middle-left {
	left: var(--fcc-wx, 20px);
	top: 50%;
}

.fame-cc-widget.is-middle-right {
	right: var(--fcc-wx, 20px);
	top: 50%;
}

.fame-cc-widget-open {
	display: flex;
	align-items: center;
	gap: 10px;
	margin: 0;
	padding: 7px 18px 7px 7px;
	border: 1px solid var(--fcc-gold);
	border-radius: 999px;
	background: linear-gradient(135deg, var(--fcc-cream), var(--fcc-powder));
	box-shadow: 0 12px 30px -12px rgba(138, 58, 82, .65);
	color: var(--fcc-text);
	font-size: 14px;
	font-weight: 700;
	line-height: 1.2;
	cursor: pointer;
	animation: fcc-float 4s ease-in-out infinite;
}

.fame-cc-widget-open:hover,
.fame-cc-widget-open:focus {
	background: linear-gradient(135deg, #fff, var(--fcc-powder));
	color: var(--fcc-text);
}

.fame-cc-widget-icon {
	position: relative;
	display: block;
	flex: 0 0 46px;
	width: 46px;
	height: 46px;
}

.fame-cc-widget-icon .fame-cc-icon {
	width: 100%;
	height: 100%;
}

.fame-cc-widget-day {
	position: absolute;
	right: -5px;
	top: -5px;
	min-width: 22px;
	height: 22px;
	padding: 0 5px;
	border: 1px solid var(--fcc-cream);
	border-radius: 11px;
	background: var(--fcc-text);
	color: #fff;
	font-size: 12px;
	font-weight: 700;
	line-height: 20px;
	text-align: center;
}

.fame-cc-widget-close {
	width: 24px;
	height: 24px;
	margin: -8px 0 0 -10px;
	padding: 0;
	border: 1px solid var(--fcc-light);
	border-radius: 50%;
	background: #fff;
	color: var(--fcc-text);
	font-size: 16px;
	line-height: 1;
	cursor: pointer;
}

.fame-cc-widget.is-size-s .fame-cc-widget-icon {
	flex-basis: 36px;
	width: 36px;
	height: 36px;
}

.fame-cc-widget.is-size-s .fame-cc-widget-open {
	font-size: 13px;
}

.fame-cc-widget.is-size-l .fame-cc-widget-icon {
	flex-basis: 58px;
	width: 58px;
	height: 58px;
}

.fame-cc-widget.is-size-l .fame-cc-widget-open {
	font-size: 16px;
}

@media (max-width: 600px) {
	.fame-cc-widget.is-desktop-only {
		display: none !important;
	}

	.fame-cc-widget-open {
		padding: 6px;
	}

	.fame-cc-widget-text {
		position: absolute;
		width: 1px;
		height: 1px;
		margin: -1px;
		overflow: hidden;
		clip: rect(0 0 0 0);
		white-space: nowrap;
	}
}

/* ---------- Cart progress ---------- */

.fame-cc-progress-wrap:empty {
	display: none;
}

.fame-cc-progress {
	display: flex;
	align-items: center;
	gap: 14px;
	margin: 0 0 18px;
	padding: 14px 18px;
	border: 1px solid var(--fcc-gold);
	border-radius: 16px;
	background: linear-gradient(135deg, var(--fcc-cream), var(--fcc-powder));
	color: var(--fcc-text);
	text-align: left;
}

.fame-cc-progress-icon {
	flex: 0 0 44px;
}

.fame-cc-progress-icon .fame-cc-icon {
	display: block;
	width: 44px;
	height: 44px;
}

.fame-cc-progress-body {
	flex: 1 1 auto;
	min-width: 0;
}

.fame-cc-progress-text {
	margin: 0 0 8px;
	padding: 0;
	font-size: 15px;
	font-weight: 600;
	line-height: 1.35;
	color: var(--fcc-text);
}

.fame-cc-progress .fame-cc-progress-text:last-child {
	margin-bottom: 0;
}

.fame-cc-bar {
	height: 10px;
	overflow: hidden;
	border-radius: 999px;
	background: rgba(255, 255, 255, .85);
	box-shadow: inset 0 0 0 1px var(--fcc-light);
}

.fame-cc-bar > span {
	display: block;
	height: 100%;
	border-radius: 999px;
	background: linear-gradient(90deg, var(--fcc-primary), var(--fcc-primary-deep));
	transition: width .6s ease;
}

.fame-cc-progress.is-done .fame-cc-bar > span {
	background: linear-gradient(90deg, var(--fcc-champagne), var(--fcc-gold));
}

.fame-cc-progress.is-blocked .fame-cc-bar > span {
	background: var(--fcc-light);
}

.fame-cc-progress-gift {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px 10px;
	margin-top: 10px;
	font-size: 14px;
}

.fame-cc-progress-gift img {
	width: 44px;
	height: 44px;
	border-radius: 8px;
	object-fit: cover;
	box-shadow: 0 0 0 1px var(--fcc-champagne);
}

.fame-cc-progress-gift-name {
	font-weight: 600;
}

.fame-cc-progress-gift-price {
	font-weight: 700;
}

/* The mini-cart bar is the first row of the product list and stays pinned to its top
   while the products scroll underneath (the row is opaque, gap below included). */
.fame-cc-progress-item {
	position: sticky;
	top: 0;
	z-index: 3;
	display: block;
	flex: 0 0 auto;
	margin: 0;
	padding: 0 0 12px;
	border: 0;
	background: var(--fcc-panel-bg, #fff);
	list-style: none;
}

.fame-cc-progress-item .fame-cc-progress-wrap.is-mini .fame-cc-progress {
	margin-bottom: 0;
}

/* Same gap above the card as below it: the theme's panel padding (30 px) is meant for a
   product row, which brings its own white space; the card does not. */
.ra-cart-modal .modal-content:has(.fame-cc-progress-item) {
	padding-top: 12px;
}

.fame-cc-progress-item::before,
.fame-cc-progress-item::after {
	content: none;
}

.fame-cc-progress-wrap.is-mini .fame-cc-progress {
	gap: 10px;
	margin: 0 0 12px;
	padding: 10px 12px;
	border-radius: 12px;
}

.fame-cc-progress-wrap.is-mini .fame-cc-progress-icon,
.fame-cc-progress-wrap.is-mini .fame-cc-progress-icon .fame-cc-icon {
	flex-basis: 30px;
	width: 30px;
	height: 30px;
}

.fame-cc-progress-wrap.is-mini .fame-cc-progress-text {
	font-size: 13px;
}

/* Used inside WooCommerce tables too, so it must not rely on the .fame-cc variables. */
.fame-cc-gratis {
	display: inline-block;
	padding: 2px 9px;
	border-radius: 999px;
	background: linear-gradient(135deg, #E8D5A8, #D4AF37);
	color: #3D2B00;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: .08em;
	line-height: 1.5;
	vertical-align: middle;
}

.fame-cc-gift-thumb {
	border-radius: 8px;
}

/* A gift line sits where the purchased products around it sit: same picture column,
   name on the first text line in the same type, badge and price on one line. */
.woocommerce-mini-cart-item__thumbnail .fame-cc-gift-thumb {
	width: 120px;
	height: auto;
}

.woocommerce-mini-cart-item.fame-cc-gift-line .woocommerce-mini-cart-item__summary {
	align-self: flex-start;
}

.woocommerce-cart-form table.shop_table tr.fame-cc-gift-line td.product-content {
	justify-content: flex-start; /* The theme centres the text block; a gift has less text than a product. */
	vertical-align: top;
}

.woocommerce-cart-form .fame-cc-gift-line .product-name {
	color: var(--rz-color-dark, #111);
	font-size: 16px;
	font-weight: 500;
}

.fame-cc-gift-line .product-price,
.fame-cc-gift-line .product-subtotal,
.fame-cc-gift-line .product-total,
.fame-cc-gift-line .woocommerce-mini-cart-item__price {
	white-space: nowrap;
}

/* ---------- Keyframes ---------- */

@keyframes fcc-twinkle {
	0%, 100% { opacity: .5; }
	50% { opacity: .75; }
}

@keyframes fcc-glow {
	0%, 100% { opacity: .55; transform: scale(.92); }
	50% { opacity: 1; transform: scale(1.06); }
}

@keyframes fcc-bow {
	0%, 70%, 100% { transform: rotate(0deg); }
	78% { transform: rotate(-5deg); }
	86% { transform: rotate(5deg); }
	93% { transform: rotate(-2deg); }
}

@keyframes fcc-spark {
	0%, 100% { opacity: .5; transform: scale(.8) rotate(0deg); }
	50% { opacity: 1; transform: scale(1.15) rotate(20deg); }
}

@keyframes fcc-pop {
	0% { transform: scale(1.07); }
	35% { transform: scale(1.18); }
	100% { transform: scale(1.13); }
}

@keyframes fcc-lid {
	0% { transform: translate(0, 0) rotate(0deg); }
	22% { transform: translate(0, -3px) rotate(0deg); }
	100% { transform: translate(-9px, -30px) rotate(-17deg); }
}

@keyframes fcc-untie {
	0% { opacity: 1; transform: translate(0, 0) scale(1); }
	35% { opacity: 1; transform: translate(0, -5px) scale(1.08) rotate(-4deg); }
	100% { opacity: 0; transform: translate(0, -15px) scale(1.2) rotate(6deg); }
}

@keyframes fcc-burst {
	0% { opacity: .2; transform: scale(.6); }
	45% { opacity: 1; }
	100% { opacity: 0; transform: scale(1.55); }
}

@keyframes fcc-confetti {
	0% { opacity: 0; transform: translate(-50%, 0) rotate(0deg); }
	15% { opacity: 1; }
	100% { opacity: 0; transform: translate(calc(-50% + var(--dx, 0px)), var(--dy, -60px)) rotate(var(--r, 180deg)); }
}

@keyframes fcc-shake {
	0%, 100% { transform: translateX(0); }
	25% { transform: translateX(-4px); }
	50% { transform: translateX(4px); }
	75% { transform: translateX(-2px); }
}

@keyframes fcc-float {
	0%, 100% { transform: translateY(0); }
	50% { transform: translateY(-4px); }
}

/* ---------- Reduced motion / animations switched off in the campaign ---------- */

.fame-cc.fame-cc-no-motion *,
.fame-cc.fame-cc-no-motion *::before,
.fame-cc.fame-cc-no-motion *::after,
.fame-cc.fame-cc-no-motion {
	animation: none !important;
	transition: none !important;
}

@media (prefers-reduced-motion: reduce) {
	.fame-cc,
	.fame-cc *,
	.fame-cc *::before,
	.fame-cc *::after {
		animation: none !important;
		transition: none !important;
	}
}
