/* ==========================================================================
   Black Friday: popup + /black-friday/ page (loaded only while the campaign runs)
   ========================================================================== */

.bf-page,
.bf-pop,
.bf-bar {
	--bf-bg: #04070f;
	--bf-surface: #0a1222;
	--bf-surface-2: #0f1a30;
	--bf-line: rgba(132, 192, 255, .14);
	--bf-text: #eef5ff;
	--bf-muted: #9fb2cf;
	--bf-glow: rgba(30, 144, 255, .55);
}

/* ---------- Shared bits ---------- */
.bf-tag {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 6px 12px;
	border-radius: 999px;
	border: 1px solid rgba(132, 192, 255, .35);
	background: rgba(30, 144, 255, .12);
	color: #cfe6ff;
	font: 700 12px/1 var(--mono);
	letter-spacing: .14em;
	direction: ltr;
}
.bf-tag .icon { color: var(--blue-300); }

.bf-count {
	display: flex;
	gap: 12px;
	justify-content: center;
	direction: ltr;
}
.bf-count__cell {
	min-width: 84px;
	padding: 14px 10px 10px;
	border-radius: 18px;
	background: linear-gradient(180deg, rgba(255, 255, 255, .07), rgba(255, 255, 255, .02));
	border: 1px solid var(--bf-line);
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06), 0 20px 40px -24px var(--bf-glow);
	text-align: center;
}
.bf-count__num {
	display: block;
	font-size: clamp(30px, 5vw, 46px);
	font-weight: 800;
	line-height: 1;
	color: #fff;
	font-variant-numeric: tabular-nums;
	text-shadow: 0 0 24px rgba(30, 144, 255, .55);
}
.bf-count__lbl {
	display: block;
	margin-top: 8px;
	font-size: 12px;
	color: var(--bf-muted);
}
.bf-count--sm { gap: 8px; }
.bf-count--sm .bf-count__cell { min-width: 0; flex: 1; padding: 10px 6px 8px; border-radius: 14px; }
.bf-count--sm .bf-count__num { font-size: 26px; }
.bf-count--sm .bf-count__lbl { font-size: 11px; margin-top: 5px; }

/* State switches: the root carries data-state = soon | live | ended; anything marked for other states hides. */
[data-state="soon"] :is(.bf-show-live, .bf-show-ended):not(.bf-show-soon),
[data-state="live"] :is(.bf-show-soon, .bf-show-ended):not(.bf-show-live),
[data-state="ended"] :is(.bf-show-soon, .bf-show-live):not(.bf-show-ended) { display: none !important; }
.bf-code__lock, .bf-code__live { display: flex; }
.bf-when { display: none; }
[data-state="soon"] .bf-when--soon,
[data-state="live"] .bf-when--live { display: inline; }

/* ---------- Page ---------- */
.bf-page {
	background: var(--bf-bg);
	color: var(--bf-text);
	overflow: hidden;
}
.bf-page h1, .bf-page h2, .bf-page h3 { color: #fff; }

.bf-preview {
	padding: 10px 16px;
	background: #f59e0b;
	color: #1a1200;
	text-align: center;
	font-size: 14px;
	font-weight: 600;
}

.bf-hero {
	position: relative;
	padding: clamp(56px, 9vw, 110px) 0 clamp(56px, 8vw, 96px);
	text-align: center;
	isolation: isolate;
}
.bf-hero::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -2;
	background:
		radial-gradient(60% 55% at 50% 0%, rgba(30, 144, 255, .35), transparent 70%),
		radial-gradient(40% 40% at 85% 90%, rgba(11, 106, 214, .25), transparent 70%),
		radial-gradient(35% 35% at 10% 80%, rgba(63, 164, 255, .16), transparent 70%);
}
.bf-hero::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background-image: linear-gradient(rgba(132, 192, 255, .06) 1px, transparent 1px), linear-gradient(90deg, rgba(132, 192, 255, .06) 1px, transparent 1px);
	background-size: 44px 44px;
	mask-image: radial-gradient(70% 70% at 50% 30%, #000, transparent 75%);
}
.bf-hero__bg {
	position: absolute;
	inset: auto 0 6% 0;
	z-index: -1;
	text-align: center;
	pointer-events: none;
	user-select: none;
}
.bf-hero__bg span {
	display: inline-block;
	font: 900 clamp(64px, 16vw, 220px)/.9 var(--font);
	letter-spacing: -.02em;
	color: transparent;
	-webkit-text-stroke: 1px rgba(132, 192, 255, .14);
	white-space: nowrap;
	direction: ltr;
}
.bf-hero__in { display: flex; flex-direction: column; align-items: center; gap: 18px; }
.bf-hero__title {
	margin: 4px 0 0;
	font-size: clamp(34px, 6.4vw, 68px);
	font-weight: 900;
	line-height: 1.15;
	background: linear-gradient(180deg, #fff 30%, #9ccdff);
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent !important;
}
.bf-hero__sub { margin: 0; max-width: 640px; color: var(--bf-muted); font-size: clamp(15px, 2vw, 18px); line-height: 1.9; }
.bf-hero__max {
	margin: 0;
	font-size: clamp(22px, 3.6vw, 32px);
	font-weight: 800;
	color: var(--blue-300);
}
.bf-status p {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin: 0;
	padding: 8px 16px;
	border-radius: 999px;
	background: rgba(255, 255, 255, .05);
	border: 1px solid var(--bf-line);
	color: #d7e6fb;
	font-size: 14px;
}
.bf-dot {
	width: 9px;
	height: 9px;
	border-radius: 50%;
	background: #10b981;
	box-shadow: 0 0 0 0 rgba(16, 185, 129, .6);
	animation: bf-pulse 1.8s infinite;
}
@keyframes bf-pulse { 70% { box-shadow: 0 0 0 10px rgba(16, 185, 129, 0); } 100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); } }
.bf-count-lbl { margin: 8px 0 12px; color: var(--bf-muted); font-size: 14px; }
.bf-hero__cta { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-top: 8px; }
.bf-hero__cta .btn { gap: 8px; }
.bf-btn-ghost { background: rgba(255, 255, 255, .06); color: #fff; border: 1px solid var(--bf-line); }
.bf-btn-ghost:hover { color: #fff; background: rgba(255, 255, 255, .1); }

.bf-head { text-align: center; max-width: 680px; margin: 0 auto 36px; }
.bf-head h2 { margin: 0 0 10px; font-size: clamp(24px, 3.6vw, 34px); font-weight: 800; }
.bf-head p { margin: 0; color: var(--bf-muted); line-height: 1.9; }

.bf-codes { padding: 20px 0 72px; }
.bf-list {
	display: flex;
	flex-direction: column;
	gap: 14px;
	max-width: 1040px;
	margin: 0 auto;
}
/* One service per row: icon | name + description | discount | code */
.bf-card {
	position: relative;
	display: grid;
	grid-template-columns: 56px minmax(0, 1fr) 130px minmax(260px, 340px);
	grid-template-areas: "icon info pct code";
	align-items: center;
	gap: 20px;
	padding: 18px 22px;
	border-radius: 20px;
	background: linear-gradient(90deg, var(--bf-surface-2), var(--bf-surface));
	border: 1px solid var(--bf-line);
	transition: border-color .25s, box-shadow .25s;
}
.bf-card::before {
	content: "";
	position: absolute;
	inset-block: 18px;
	inset-inline-start: 0;
	width: 3px;
	border-radius: 3px;
	background: linear-gradient(180deg, transparent, var(--blue), transparent);
}
.bf-card:hover { border-color: rgba(132, 192, 255, .32); box-shadow: 0 24px 50px -30px var(--bf-glow); }
.bf-card__icon {
	grid-area: icon;
	display: grid;
	place-items: center;
	width: 56px;
	height: 56px;
	border-radius: 16px;
	background: rgba(30, 144, 255, .14);
	border: 1px solid rgba(132, 192, 255, .25);
	color: var(--blue-300);
}
.bf-card__info { grid-area: info; min-width: 0; }
.bf-card__pct { grid-area: pct; display: flex; align-items: baseline; justify-content: center; gap: 2px; color: #fff; }
.bf-card__pct b {
	font-size: 40px;
	font-weight: 900;
	line-height: 1;
	background: linear-gradient(180deg, #fff, #7cbcff);
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
}
.bf-card__pct i { font-style: normal; font-size: 22px; font-weight: 800; color: #7cbcff; }
.bf-card__pct small { margin-inline-start: 6px; font-size: 13px; color: var(--bf-muted); }
[data-state="soon"] .bf-card__pct b { opacity: .7; }
.bf-card__title { margin: 0 0 4px; font-size: 18px; font-weight: 800; }
.bf-card__desc { margin: 0; color: var(--bf-muted); font-size: 13.5px; line-height: 1.8; }
.bf-card .bf-code { grid-area: code; }

.bf-code__lock,
.bf-code__live {
	align-items: center;
	gap: 10px;
	min-height: 54px;
	padding: 8px 8px 8px 14px;
	border-radius: 14px;
	border: 1.5px dashed rgba(132, 192, 255, .35);
	background: rgba(4, 7, 15, .55);
}
html[dir="rtl"] .bf-code__lock,
html[dir="rtl"] .bf-code__live { padding: 8px 14px 8px 8px; }
.bf-code__lock { justify-content: space-between; color: var(--bf-muted); font-size: 13px; cursor: not-allowed; }
.bf-code__mask {
	font: 800 18px/1.2 var(--mono);
	letter-spacing: .12em;
	color: #fff;
	filter: blur(5px);
	opacity: .55;
	user-select: none;
}
.bf-code__when {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 8px 12px;
	border-radius: 10px;
	background: rgba(255, 255, 255, .06);
	border: 1px solid var(--bf-line);
	color: #cfe2fb;
	font-weight: 700;
	white-space: nowrap;
}
.bf-code__when .icon { color: var(--blue-300); }
.bf-code__val {
	flex: 1;
	min-width: 0;
	font: 800 18px/1.2 var(--mono);
	letter-spacing: .12em;
	color: #fff;
	background: none;
	padding: 0;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}
.bf-code__copy {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 10px 14px;
	border: 0;
	border-radius: 10px;
	background: var(--grad);
	color: #fff;
	font: 700 13px/1 var(--font);
	cursor: pointer;
	white-space: nowrap;
	transition: transform .2s, box-shadow .2s;
}
.bf-code__copy:hover { transform: translateY(-1px); box-shadow: 0 10px 24px -10px var(--bf-glow); }
.bf-code__copy.is-done { background: #10b981; }
.bf-code__soon { display: none; flex: 1; text-align: center; color: var(--bf-muted); font-size: 14px; }
.bf-card[data-empty] .bf-code__val,
.bf-card[data-empty] .bf-code__copy { display: none; }
.bf-card[data-empty] .bf-code__soon { display: block; }

.bf-card__go {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	margin-top: 6px;
	color: #9ccdff;
	font-size: 14px;
	font-weight: 600;
}
.bf-card__go:hover { color: #fff; }

.bf-how { padding: 64px 0 88px; background: linear-gradient(180deg, transparent, rgba(30, 144, 255, .05)); border-top: 1px solid var(--bf-line); }
.bf-steps {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
	gap: 18px;
	margin: 0;
	padding: 0;
	list-style: none;
}
.bf-steps li {
	padding: 22px;
	border-radius: 18px;
	background: var(--bf-surface);
	border: 1px solid var(--bf-line);
}
.bf-steps span {
	display: grid;
	place-items: center;
	width: 38px;
	height: 38px;
	margin-bottom: 12px;
	border-radius: 12px;
	background: var(--grad);
	color: #fff;
	font-weight: 800;
}
.bf-steps b { display: block; margin-bottom: 6px; color: #fff; font-size: 16px; }
.bf-steps p { margin: 0; color: var(--bf-muted); font-size: 14px; line-height: 1.8; }
.bf-terms { max-width: 760px; margin: 40px auto 0; padding: 22px 26px; border-radius: 18px; border: 1px solid var(--bf-line); background: rgba(255, 255, 255, .02); }
.bf-terms h3 { margin: 0 0 10px; font-size: 16px; }
.bf-terms ul { margin: 0; padding-inline-start: 20px; color: var(--bf-muted); font-size: 14px; line-height: 2; }

/* ---------- Popup ---------- */
.bf-pop {
	position: fixed;
	inset: 0;
	z-index: 1000;
	display: grid;
	place-items: center;
	padding: 16px;
}
.bf-pop[hidden] { display: none; }
.bf-pop__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(2, 6, 16, .62);
	backdrop-filter: blur(6px);
	-webkit-backdrop-filter: blur(6px);
	animation: bf-fade .3s ease both;
}
.bf-pop__dialog {
	position: relative;
	width: min(100%, 420px);
	border-radius: 26px;
	background: var(--bf-bg);
	border: 1px solid rgba(132, 192, 255, .22);
	box-shadow: 0 40px 90px -30px rgba(30, 144, 255, .6), 0 0 0 1px rgba(255, 255, 255, .03) inset;
	overflow: hidden;
	animation: bf-rise .45s var(--ease) both;
}
.bf-pop__close {
	position: absolute;
	top: 12px;
	inset-inline-end: 12px;
	z-index: 2;
	display: grid;
	place-items: center;
	width: 36px;
	height: 36px;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, .08);
	color: #dbe9ff;
	cursor: pointer;
}
.bf-pop__close:hover { background: rgba(255, 255, 255, .16); color: #fff; }
.bf-pop__body {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 12px;
	padding: 34px 26px 26px;
	text-align: center;
	color: var(--bf-text);
	text-decoration: none;
	isolation: isolate;
}
.bf-pop__body:hover { color: var(--bf-text); }
.bf-pop__glow {
	position: absolute;
	inset: -40% -20% auto;
	height: 120%;
	z-index: -1;
	background: radial-gradient(50% 50% at 50% 30%, rgba(30, 144, 255, .45), transparent 70%);
	pointer-events: none;
}
.bf-pop__big {
	font-size: 46px;
	font-weight: 900;
	line-height: 1;
	background: linear-gradient(180deg, #fff, #7cbcff);
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
}
.bf-pop__big small { margin-inline-start: 6px; font-size: 18px; }
.bf-pop__title { font-size: 22px; font-weight: 900; color: #fff; }
.bf-pop__text { color: var(--bf-muted); font-size: 14px; line-height: 1.9; }
.bf-pop__when { margin-top: 4px; color: #cfe2fb; font-size: 13px; font-weight: 600; }
.bf-pop .bf-count { width: 100%; }
.bf-pop__cta {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	width: 100%;
	margin-top: 6px;
	padding: 14px 18px;
	border-radius: 14px;
	background: var(--grad);
	color: #fff;
	font-weight: 800;
	box-shadow: 0 14px 30px -12px var(--bf-glow);
	transition: transform .2s;
}
.bf-pop__body:hover .bf-pop__cta { transform: translateY(-2px); }

/* ---------- Top banner ---------- */
.bf-bar {
	position: relative;
	z-index: 60;
	background: linear-gradient(90deg, #04070f, #0b1a36 50%, #04070f);
	border-bottom: 1px solid rgba(132, 192, 255, .22);
	color: var(--bf-text);
	overflow: hidden;
}
.bf-bar::after {
	content: "";
	position: absolute;
	inset: 0;
	background: radial-gradient(40% 140% at 50% 0%, rgba(30, 144, 255, .28), transparent 70%);
	pointer-events: none;
}
.bf-bar[data-state="ended"],
.bf-bar[hidden] { display: none; }
.bf-bar__close {
	position: absolute;
	top: 50%;
	inset-inline-end: 10px;
	z-index: 2;
	display: grid;
	place-items: center;
	width: 30px;
	height: 30px;
	margin-top: -15px;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, .08);
	color: #cfe2fb;
	cursor: pointer;
}
.bf-bar__close:hover { background: rgba(255, 255, 255, .18); color: #fff; }
.bf-bar__in {
	position: relative;
	z-index: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 18px;
	min-height: 52px;
	padding-block: 8px;
	padding-inline-end: 52px;
	color: inherit;
	text-decoration: none;
}
.bf-bar__in:hover { color: inherit; }
.bf-bar__tag {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	padding: 5px 10px;
	border-radius: 999px;
	background: rgba(30, 144, 255, .16);
	border: 1px solid rgba(132, 192, 255, .35);
	color: #cfe6ff;
	font: 700 11px/1 var(--mono);
	letter-spacing: .12em;
	direction: ltr;
	white-space: nowrap;
}
.bf-bar__text { display: flex; align-items: center; gap: 10px; min-width: 0; font-size: 14px; }
.bf-bar__text b { color: #fff; white-space: nowrap; }
.bf-bar__max { padding: 3px 9px; border-radius: 8px; background: var(--grad); color: #fff; font-size: 13px; font-weight: 800; white-space: nowrap; }
.bf-bar__sub { color: var(--bf-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bf-bar__timer { display: flex; align-items: center; gap: 8px; }
.bf-bar__lbl { color: var(--bf-muted); font-size: 12px; white-space: nowrap; }
.bf-bar__count { display: flex; gap: 4px; direction: ltr; }
.bf-bar__cell {
	display: flex;
	align-items: baseline;
	gap: 3px;
	padding: 4px 7px;
	border-radius: 8px;
	background: rgba(255, 255, 255, .07);
	border: 1px solid var(--bf-line);
}
.bf-bar__cell b { font-size: 16px; font-weight: 800; color: #fff; font-variant-numeric: tabular-nums; }
.bf-bar__cell small { font-size: 10px; color: var(--bf-muted); }
.bf-bar__cta {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 8px 14px;
	border-radius: 10px;
	background: var(--grad);
	color: #fff;
	font-size: 13px;
	font-weight: 800;
	white-space: nowrap;
	box-shadow: 0 10px 24px -12px var(--bf-glow);
	transition: transform .2s;
}
.bf-bar__in:hover .bf-bar__cta { transform: translateY(-1px); }

@media (max-width: 1100px) {
	.bf-bar__sub { display: none; }
}
@media (max-width: 900px) {
	.bf-card {
		grid-template-columns: 52px minmax(0, 1fr) auto;
		grid-template-areas: "icon info pct" "code code code";
		gap: 14px 16px;
	}
	.bf-card__icon { width: 52px; height: 52px; }
}
@media (max-width: 720px) {
	.bf-bar__in { flex-wrap: wrap; gap: 6px 8px; padding-block: 7px; padding-inline-end: 44px; }
	.bf-bar__close { width: 26px; height: 26px; margin-top: -13px; inset-inline-end: 8px; }
	.bf-bar__tag, .bf-bar__lbl { display: none; }
	.bf-bar__text { flex-basis: 100%; justify-content: center; font-size: 13px; }
	.bf-bar__max { padding: 2px 7px; font-size: 12px; }
	.bf-bar__count { gap: 3px; }
	.bf-bar__cta { padding: 6px 9px; font-size: 12px; }
	.bf-bar__cell { gap: 2px; padding: 3px 5px; }
	.bf-bar__cell b { font-size: 13px; }
	.bf-bar__cell small { font-size: 9px; }
}

@keyframes bf-fade { from { opacity: 0; } }
@keyframes bf-rise { from { opacity: 0; transform: translateY(24px) scale(.97); } }

@media (max-width: 560px) {
	.bf-pop { place-items: end center; padding: 0; }
	.bf-pop__dialog { width: 100%; border-radius: 24px 24px 0 0; }
	.bf-count { gap: 8px; }
	.bf-count__cell { min-width: 0; flex: 1; padding: 12px 6px 8px; }
	.bf-pop__dialog { max-height: 92vh; max-height: 92dvh; overflow-y: auto; }

	/* Hero */
	.bf-hero { padding: 40px 0 44px; }
	.bf-hero__in { gap: 14px; }
	.bf-hero__title { font-size: 32px; }
	.bf-hero__sub { font-size: 14.5px; line-height: 1.8; }
	.bf-hero__max { font-size: 22px; }
	.bf-status p { justify-content: center; padding: 8px 14px; border-radius: 14px; font-size: 13px; line-height: 1.7; text-align: center; }
	.bf-count-lbl { margin: 4px 0 10px; font-size: 13px; }
	.bf-hero__cta { width: 100%; }
	.bf-hero__cta .btn { flex: 1 1 100%; justify-content: center; }

	/* Section heads */
	.bf-head { margin-bottom: 22px; }
	.bf-head h2 { font-size: 23px; }
	.bf-head p { font-size: 14px; }
	.bf-codes { padding: 12px 0 48px; }

	/* Service rows: icon + name on top, discount strip, then the code */
	.bf-list { gap: 12px; }
	.bf-card {
		grid-template-columns: 46px minmax(0, 1fr);
		grid-template-areas: "icon info" "pct pct" "code code";
		gap: 12px;
		padding: 16px;
		border-radius: 18px;
	}
	.bf-card::before { inset-block: 16px; }
	.bf-card__icon { width: 46px; height: 46px; border-radius: 14px; }
	.bf-card__icon .icon { width: 22px; height: 22px; }
	.bf-card__title { font-size: 16.5px; }
	.bf-card__desc { font-size: 13px; line-height: 1.7; }
	.bf-card__go { font-size: 13px; }
	.bf-card__pct {
		justify-self: stretch;
		justify-content: flex-start;
		align-items: center;
		padding: 8px 12px;
		border-radius: 12px;
		background: rgba(30, 144, 255, .1);
		border: 1px solid rgba(132, 192, 255, .18);
	}
	.bf-card__pct b { font-size: 26px; }
	.bf-card__pct i { font-size: 17px; }
	.bf-code__lock,
	.bf-code__live { min-height: 50px; }
	.bf-code__val, .bf-code__mask { font-size: 16px; letter-spacing: .08em; }
	.bf-code__when { padding: 7px 10px; font-size: 12.5px; }

	/* How-to steps: number beside the text */
	.bf-how { padding: 44px 0 56px; }
	.bf-steps { gap: 10px; }
	.bf-steps li { display: grid; grid-template-columns: 36px minmax(0, 1fr); column-gap: 12px; align-items: start; padding: 14px 16px; border-radius: 16px; }
	.bf-steps span { grid-row: span 2; width: 36px; height: 36px; margin: 0; border-radius: 11px; }
	.bf-steps b { margin: 6px 0 2px; font-size: 15px; }
	.bf-steps p { font-size: 13px; line-height: 1.7; }
	.bf-terms { margin-top: 24px; padding: 16px 18px; border-radius: 16px; }
	.bf-terms ul { font-size: 13px; line-height: 1.9; }
}
@media (max-width: 360px) {
	.bf-hero__title { font-size: 28px; }
	.bf-count__cell { padding: 10px 4px 7px; border-radius: 14px; }
	.bf-count__num { font-size: 26px; }
	.bf-code__copy span { display: none; }
	.bf-code__copy { padding: 10px; }
	.bf-code__when { font-size: 11.5px; }
}

@media (prefers-reduced-motion: reduce) {
	.bf-pop__backdrop, .bf-pop__dialog, .bf-dot { animation: none; }
	.bf-card, .bf-card:hover, .bf-bar__cta { transition: none; transform: none; }
}
