/* KS Spin & Win — storefront */
.ksw {
	--ksw-primary: #7C3AED;
	--ksw-accent: #FBBF24;
	--ksw-bg1: #160A2E;
	--ksw-bg2: #4C1D95;
	--ksw-rim: #F5B82E;
	--ksw-font: inherit;
	--ksw-ease: cubic-bezier(.2, .9, .25, 1.15);
	font-family: var(--ksw-font);
	-webkit-font-smoothing: antialiased;
}
.ksw *, .ksw *::before, .ksw *::after { box-sizing: border-box; }
.ksw [hidden] { display: none !important; }
html.ksw-lock, html.ksw-lock body { overflow: hidden !important; }

/* ---------------------------------------------------------------- modal */
.ksw-modal {
	position: fixed; inset: 0; z-index: 999990;
	display: flex; align-items: center; justify-content: center;
	padding: 20px;
}
.ksw-backdrop {
	position: absolute; inset: 0;
	background: radial-gradient(ellipse at 50% 40%, rgba(40, 12, 80, .55), rgba(6, 2, 16, .82));
	-webkit-backdrop-filter: blur(0px); backdrop-filter: blur(0px);
	opacity: 0; transition: opacity .4s ease, backdrop-filter .4s ease, -webkit-backdrop-filter .4s ease;
}
.ksw-is-open .ksw-backdrop { opacity: 1; -webkit-backdrop-filter: blur(7px); backdrop-filter: blur(7px); }

.ksw-shell {
	position: relative; width: 100%; max-width: 940px;
	transform: translateY(40px) scale(.92); opacity: 0;
	transition: transform .7s var(--ksw-ease), opacity .45s ease;
}
.ksw-is-open .ksw-shell { transform: none; opacity: 1; }
.ksw[data-state="closing"] .ksw-shell { transform: translateY(24px) scale(.95); opacity: 0; transition-duration: .35s; }
.ksw-card {
	position: relative; overflow: hidden;
	width: 100%;
	display: grid; grid-template-columns: 1.08fr 1fr; align-items: center;
	border-radius: 30px;
	color: #fff;
	background:
		radial-gradient(120% 90% at 0% 0%, rgba(255, 255, 255, .10), transparent 45%),
		linear-gradient(140deg, var(--ksw-bg1) 0%, var(--ksw-bg2) 100%);
	border: 1px solid rgba(255, 255, 255, .14);
	box-shadow: 0 40px 120px -20px rgba(0, 0, 0, .7), 0 0 0 1px rgba(0, 0, 0, .2), inset 0 1px 0 rgba(255, 255, 255, .12);
}

.ksw-close {
	position: absolute; top: 14px; right: 14px; z-index: 5;
	width: 40px; height: 40px; border-radius: 50%; padding: 10px;
	display: grid; place-items: center;
	color: #fff; background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .18);
	cursor: pointer; transition: transform .25s ease, background .25s ease;
}
.ksw-close:hover { background: rgba(255, 255, 255, .2); transform: rotate(90deg); }
.ksw-close svg { width: 18px; height: 18px; }

/* animated background */
.ksw-aurora { position: absolute; inset: 0; pointer-events: none; opacity: .75; }
.ksw-aurora i { position: absolute; border-radius: 50%; will-change: transform; animation: ksw-drift 14s ease-in-out infinite alternate; }
.ksw-aurora i:nth-child(1) { width: 560px; height: 560px; left: -220px; top: -220px; background: radial-gradient(circle, var(--ksw-primary) 0%, transparent 65%); }
.ksw-aurora i:nth-child(2) { width: 480px; height: 480px; right: -180px; bottom: -200px; background: radial-gradient(circle, rgba(236, 72, 153, .6) 0%, transparent 65%); animation-delay: -5s; }
.ksw-aurora i:nth-child(3) { width: 380px; height: 380px; left: 30%; top: 20%; background: radial-gradient(circle, rgba(251, 191, 36, .22) 0%, transparent 65%); animation-delay: -9s; }
@keyframes ksw-drift { to { transform: translate(60px, 40px) scale(1.15); } }

.ksw-stars { position: absolute; inset: 0; pointer-events: none; }
.ksw-stars i {
	position: absolute; width: 3px; height: 3px; border-radius: 50%; background: #fff;
	box-shadow: 0 0 6px 1px rgba(255, 255, 255, .8);
	animation: ksw-twinkle 3s ease-in-out infinite;
}
.ksw-stars i:nth-child(1) { left: 6%; top: 12%; animation-delay: -.2s; }
.ksw-stars i:nth-child(2) { left: 18%; top: 82%; animation-delay: -1.1s; }
.ksw-stars i:nth-child(3) { left: 30%; top: 6%; animation-delay: -2.3s; }
.ksw-stars i:nth-child(4) { left: 44%; top: 92%; animation-delay: -.7s; }
.ksw-stars i:nth-child(5) { left: 52%; top: 14%; animation-delay: -1.9s; }
.ksw-stars i:nth-child(6) { left: 63%; top: 70%; animation-delay: -2.8s; }
.ksw-stars i:nth-child(7) { left: 72%; top: 8%; animation-delay: -.4s; }
.ksw-stars i:nth-child(8) { left: 81%; top: 40%; animation-delay: -1.5s; }
.ksw-stars i:nth-child(9) { left: 91%; top: 88%; animation-delay: -2.1s; }
.ksw-stars i:nth-child(10) { left: 96%; top: 22%; animation-delay: -.9s; }
.ksw-stars i:nth-child(11) { left: 4%; top: 52%; animation-delay: -2.6s; }
.ksw-stars i:nth-child(12) { left: 36%; top: 48%; animation-delay: -1.3s; width: 2px; height: 2px; }
.ksw-stars i:nth-child(13) { left: 58%; top: 40%; animation-delay: -.1s; width: 2px; height: 2px; }
.ksw-stars i:nth-child(14) { left: 86%; top: 60%; animation-delay: -1.7s; width: 2px; height: 2px; }
.ksw-stars i:nth-child(15) { left: 24%; top: 34%; animation-delay: -2.4s; width: 2px; height: 2px; }
.ksw-stars i:nth-child(16) { left: 68%; top: 94%; animation-delay: -.5s; width: 2px; height: 2px; }
.ksw-stars i:nth-child(17) { left: 12%; top: 66%; animation-delay: -1.2s; width: 2px; height: 2px; }
.ksw-stars i:nth-child(18) { left: 76%; top: 26%; animation-delay: -2.9s; width: 2px; height: 2px; }
@keyframes ksw-twinkle { 0%, 100% { opacity: .15; transform: scale(.6); } 50% { opacity: 1; transform: scale(1.2); } }

/* ---------------------------------------------------------------- stage */
.ksw-stage { position: relative; padding: 36px 10px 36px 36px; z-index: 1; }
.ksw-halo {
	position: absolute; left: 50%; top: 50%; width: 88%; aspect-ratio: 1; transform: translate(-50%, -50%);
	border-radius: 50%;
	background: conic-gradient(from 0deg, var(--ksw-accent), #EC4899, var(--ksw-primary), #22D3EE, var(--ksw-accent));
	-webkit-mask: radial-gradient(circle, transparent 42%, #000 56%, transparent 71%); mask: radial-gradient(circle, transparent 42%, #000 56%, transparent 71%);
	opacity: .55; will-change: transform;
	animation: ksw-halo 8s linear infinite;
}
@keyframes ksw-halo { to { transform: translate(-50%, -50%) rotate(360deg); } }
.ksw-wheel-mount {
	position: relative; width: 100%; max-width: 440px; margin: 0 auto; aspect-ratio: 1;
	transform: rotate(-140deg) scale(.55); opacity: 0;
	transition: transform 1.1s var(--ksw-ease) .12s, opacity .5s ease .12s;
}
.ksw-wheel-mount::before { content: ""; position: absolute; inset: 1%; border-radius: 50%; box-shadow: 0 28px 50px -6px rgba(0, 0, 0, .6); pointer-events: none; }
.ksw-is-open .ksw-wheel-mount { transform: none; opacity: 1; }
.ksw-floor {
	position: absolute; left: 50%; bottom: 14px; width: 58%; height: 26px; transform: translateX(-50%);
	background: radial-gradient(ellipse, rgba(0, 0, 0, .5), transparent 70%);
}
.ksw-svg { display: block; width: 100%; height: 100%; overflow: visible; }
.ksw-svg text { font-family: var(--ksw-font); user-select: none; -webkit-user-select: none; }
.ksw-label { font-weight: 800; letter-spacing: .02em; paint-order: stroke; stroke: rgba(0, 0, 0, .28); stroke-width: 2.4px; }
.ksw-sublabel { font-weight: 600; opacity: .88; letter-spacing: .03em; }
.ksw-hub { cursor: pointer; transition: transform .25s var(--ksw-ease); transform-origin: 250px 250px; }
.ksw-hub:hover { transform: scale(1.06); }
.ksw-hub-text { font-weight: 900; letter-spacing: .08em; paint-order: stroke; stroke: rgba(0, 0, 0, .25); stroke-width: 2px; }
.ksw[data-view="form"] .ksw-hub { animation: ksw-hub-pulse 2.2s ease-in-out infinite; }
@keyframes ksw-hub-pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.07); } }
.ksw-pointer { transform-box: fill-box; transform-origin: 50% 22%; }

/* bulbs */
.ksw-bulb { fill: #FFF6D5; }
.ksw-bulbs .ksw-bulb { animation: ksw-bulb 1.1s steps(1) infinite; }
.ksw-bulbs .ksw-b { animation-delay: -.55s; }
@keyframes ksw-bulb { 0% { fill: #FFFBEA; } 50% { fill: #9A7431; } }
.ksw-lights-spin .ksw-bulb { animation: ksw-chase .5s linear infinite; animation-delay: calc(var(--i) * -.04s); }
@keyframes ksw-chase { 0%, 30% { fill: #FFFFFF; } 31%, 100% { fill: #9A7431; } }
.ksw-lights-win .ksw-bulb { animation: ksw-flash .28s steps(1) infinite; animation-delay: 0s; }
@keyframes ksw-flash { 0% { fill: #FFFFFF; } 50% { fill: #FFC93C; } }
.ksw-bulbs-off .ksw-bulb { animation: none !important; fill: #FFE9A8; }

.ksw-winflash .ksw-card { animation: ksw-winflash 1.2s ease-out; }
@keyframes ksw-winflash {
	0% { box-shadow: 0 0 0 0 rgba(251, 191, 36, .9), 0 40px 120px -20px rgba(0, 0, 0, .7); }
	100% { box-shadow: 0 0 0 40px rgba(251, 191, 36, 0), 0 40px 120px -20px rgba(0, 0, 0, .7); }
}

/* ---------------------------------------------------------------- panel */
.ksw-panel { position: relative; z-index: 2; padding: 44px 44px 40px 20px; min-height: 420px; display: flex; align-items: center; }
.ksw-view { width: 100%; }
.ksw-view.ksw-in > * { animation: ksw-up .55s var(--ksw-ease) both; }
.ksw-view.ksw-in > *:nth-child(2) { animation-delay: .06s; }
.ksw-view.ksw-in > *:nth-child(3) { animation-delay: .12s; }
.ksw-view.ksw-in > *:nth-child(4) { animation-delay: .18s; }
.ksw-view.ksw-in > *:nth-child(5) { animation-delay: .24s; }
.ksw-view.ksw-in > *:nth-child(6) { animation-delay: .30s; }
.ksw-view.ksw-in > *:nth-child(n+7) { animation-delay: .36s; }
@keyframes ksw-up { from { opacity: 0; transform: translateY(16px); } }

.ksw-badge {
	display: inline-flex; align-items: center; gap: 6px;
	padding: 7px 14px; border-radius: 99px;
	font-size: 12px; font-weight: 700; letter-spacing: .12em;
	color: var(--ksw-accent);
	background: rgba(251, 191, 36, .12); border: 1px solid rgba(251, 191, 36, .35);
}
.ksw-title {
	margin: 14px 0 10px; padding: 0;
	font-family: var(--ksw-font); font-size: clamp(28px, 3.4vw, 40px); font-weight: 900; line-height: 1.05; letter-spacing: -.02em;
	color: #fff;
	background: linear-gradient(180deg, #fff 30%, #F3E8FF 100%); -webkit-background-clip: text; background-clip: text;
	text-shadow: 0 2px 30px rgba(168, 85, 247, .35);
}
.ksw-title-sm { font-size: 30px; text-align: center; }
.ksw-sub { margin: 0 0 22px; font-size: 15.5px; line-height: 1.55; color: rgba(255, 255, 255, .78); }

.ksw-form { display: grid; gap: 12px; }
.ksw-field { position: relative; display: block; margin: 0; }
.ksw-field-ico {
	position: absolute; left: 16px; top: 50%; transform: translateY(-50%);
	width: 19px; height: 19px; color: rgba(255, 255, 255, .55); pointer-events: none; transition: color .2s;
}
.ksw-field-ico svg { width: 100%; height: 100%; display: block; }
.ksw .ksw-field input {
	width: 100%; height: 52px; margin: 0; padding: 0 16px 0 46px;
	font: 500 15.5px/1 var(--ksw-font); color: #fff;
	background: rgba(255, 255, 255, .07);
	border: 1.5px solid rgba(255, 255, 255, .16); border-radius: 15px;
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, .05);
	outline: none; transition: border-color .2s, background .2s, box-shadow .2s;
	-webkit-appearance: none; appearance: none;
}
.ksw .ksw-field input::placeholder { color: rgba(255, 255, 255, .5); }
.ksw .ksw-field input:focus { border-color: var(--ksw-accent); background: rgba(255, 255, 255, .11); box-shadow: 0 0 0 4px rgba(251, 191, 36, .16); }
.ksw-field:focus-within .ksw-field-ico { color: var(--ksw-accent); }
.ksw-field.ksw-bad input { border-color: #FB7185; box-shadow: 0 0 0 4px rgba(251, 113, 133, .18); }
.ksw-field.ksw-bad .ksw-field-ico { color: #FB7185; }
.ksw .ksw-field input:-webkit-autofill { -webkit-text-fill-color: #fff; transition: background-color 9999s; }
.ksw-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; opacity: 0; }

.ksw-consent { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; color: rgba(255, 255, 255, .75); line-height: 1.45; cursor: pointer; }
.ksw-consent input { margin-top: 2px; accent-color: var(--ksw-accent); width: 16px; height: 16px; }

.ksw-spin-btn {
	position: relative; overflow: hidden; isolation: isolate;
	display: flex; align-items: center; justify-content: center; width: 100%; height: 58px; margin: 6px 0 0;
	border: 0; border-radius: 16px; cursor: pointer; text-decoration: none !important;
	font: 900 17px/1 var(--ksw-font); letter-spacing: .14em; color: #2A1300 !important;
	background: linear-gradient(135deg, #FFE27A 0%, var(--ksw-accent) 45%, #F59E0B 100%);
	box-shadow: 0 12px 30px -8px rgba(245, 158, 11, .75), inset 0 -3px 0 rgba(0, 0, 0, .14), inset 0 2px 0 rgba(255, 255, 255, .55);
	transition: transform .2s var(--ksw-ease), box-shadow .2s ease, filter .2s;
	animation: ksw-btn-glow 2.4s ease-in-out infinite;
}
.ksw-spin-btn:hover { transform: translateY(-2px); filter: saturate(1.1) brightness(1.04); }
.ksw-spin-btn:active { transform: translateY(1px) scale(.99); }
@keyframes ksw-btn-glow {
	0%, 100% { box-shadow: 0 12px 30px -8px rgba(245, 158, 11, .75), inset 0 -3px 0 rgba(0, 0, 0, .14), inset 0 2px 0 rgba(255, 255, 255, .55); }
	50% { box-shadow: 0 14px 44px -6px rgba(251, 191, 36, 1), inset 0 -3px 0 rgba(0, 0, 0, .14), inset 0 2px 0 rgba(255, 255, 255, .55); }
}
.ksw-spin-btn-shine {
	position: absolute; inset: 0; z-index: -1;
	background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, .75) 50%, transparent 65%);
	transform: translateX(-120%); animation: ksw-shine 3.2s ease-in-out infinite;
}
@keyframes ksw-shine { 0%, 55% { transform: translateX(-120%); } 85%, 100% { transform: translateX(120%); } }
.ksw-busy .ksw-spin-btn { pointer-events: none; filter: grayscale(.2) brightness(.9); }
.ksw-busy .ksw-spin-btn-txt { opacity: 0; }
.ksw-busy .ksw-spin-btn::after {
	content: ""; position: absolute; width: 22px; height: 22px; border-radius: 50%;
	border: 3px solid rgba(42, 19, 0, .25); border-top-color: #2A1300; animation: ksw-rot .7s linear infinite;
}
@keyframes ksw-rot { to { transform: rotate(360deg); } }

.ksw-error { margin: 2px 0 0; min-height: 18px; font-size: 13.5px; font-weight: 600; color: #FDA4AF; }
.ksw-error:empty { min-height: 0; }
.ksw-shake { animation: ksw-shake .45s ease; }
@keyframes ksw-shake { 20%, 60% { transform: translateX(-7px); } 40%, 80% { transform: translateX(7px); } }
.ksw-fine { margin: 14px 0 0; font-size: 12px; color: rgba(255, 255, 255, .5); text-align: center; }

/* spinning */
.ksw-view-spinning { text-align: center; }
.ksw-luck { font-size: 64px; line-height: 1; animation: ksw-bob 1.2s ease-in-out infinite; }
@keyframes ksw-bob { 50% { transform: translateY(-10px) rotate(12deg); } }
.ksw-dots { display: flex; justify-content: center; gap: 8px; margin-top: 8px; }
.ksw-dots i { width: 10px; height: 10px; border-radius: 50%; background: var(--ksw-accent); animation: ksw-dot 1s ease-in-out infinite; }
.ksw-dots i:nth-child(2) { animation-delay: .15s; }
.ksw-dots i:nth-child(3) { animation-delay: .3s; }
@keyframes ksw-dot { 0%, 100% { transform: scale(.5); opacity: .4; } 50% { transform: scale(1); opacity: 1; } }

.ksw-view-loading { display: flex; justify-content: center; }
.ksw-loader { width: 44px; height: 44px; border-radius: 50%; border: 4px solid rgba(255, 255, 255, .15); border-top-color: var(--ksw-accent); animation: ksw-rot .8s linear infinite; }

/* result */
.ksw-view-result { text-align: center; }
.ksw-prize-burst { position: relative; width: 112px; height: 112px; margin: 0 auto 6px; display: grid; place-items: center; }
.ksw-rays {
	position: absolute; inset: -34px; border-radius: 50%;
	background: repeating-conic-gradient(from 0deg, rgba(251, 191, 36, .45) 0deg 8deg, transparent 8deg 22deg);
	-webkit-mask: radial-gradient(circle, #000 18%, transparent 68%); mask: radial-gradient(circle, #000 18%, transparent 68%);
	animation: ksw-rot 12s linear infinite;
}
.ksw-prize-icon {
	position: relative; width: 96px; height: 96px; border-radius: 50%;
	display: grid; place-items: center; font-size: 50px; line-height: 1;
	background: radial-gradient(circle at 35% 30%, #fff, #FFF1C2 45%, var(--ksw-accent));
	box-shadow: 0 0 0 6px rgba(255, 255, 255, .12), 0 14px 40px -6px rgba(251, 191, 36, .8);
	animation: ksw-pop .8s var(--ksw-ease) both;
}
@keyframes ksw-pop { from { transform: scale(0) rotate(-40deg); } }
.ksw-lose .ksw-rays { display: none; }
.ksw-lose .ksw-prize-icon { background: radial-gradient(circle at 35% 30%, #fff, #E9D5FF); box-shadow: 0 0 0 6px rgba(255, 255, 255, .1); }
.ksw-congrats { margin: 4px 0 0; font-size: 15px; font-weight: 700; color: var(--ksw-accent); }
.ksw-eyebrow { display: block; margin-top: 8px; font-size: 12px; font-weight: 800; letter-spacing: .24em; color: rgba(255, 255, 255, .6); }
.ksw-prize-title {
	margin: 4px 0 6px; font-family: var(--ksw-font); font-size: clamp(30px, 4vw, 44px); font-weight: 900; line-height: 1.05; letter-spacing: -.01em;
	background: linear-gradient(180deg, #FFF7D1 10%, var(--ksw-accent) 60%, #F59E0B 100%);
	-webkit-background-clip: text; background-clip: text; color: transparent;
	text-shadow: none;
}
.ksw-prize-text { margin: 0 0 18px; font-size: 15px; color: rgba(255, 255, 255, .82); line-height: 1.5; }
.ksw-code {
	position: relative; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 2px 12px;
	padding: 12px 12px 12px 18px; margin: 0 0 12px; text-align: left;
	border-radius: 16px; border: 2px dashed rgba(251, 191, 36, .7);
	background: rgba(251, 191, 36, .08);
}
.ksw-code-label { grid-column: 1; font-size: 11px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: rgba(255, 255, 255, .6); }
.ksw-code-value { grid-column: 1; font: 800 22px/1.2 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; letter-spacing: .08em; color: #fff; word-break: break-all; }
.ksw-copy {
	grid-column: 2; grid-row: 1 / span 2;
	height: 42px; padding: 0 18px; border: 0; border-radius: 12px; cursor: pointer;
	font: 800 14px/1 var(--ksw-font); color: #2A1300; background: var(--ksw-accent);
	transition: transform .15s, background .2s;
}
.ksw-copy:hover { transform: scale(1.04); }
.ksw-copy.ksw-copied { background: #34D399; color: #052E1B; }
.ksw-meta { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 0 0 10px; }
.ksw-meta-item { padding: 7px 12px; border-radius: 99px; font-size: 13px; color: rgba(255, 255, 255, .85); background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .12); }
.ksw-meta-item b { font-variant-numeric: tabular-nums; color: #fff; }
.ksw-note { margin: 0 0 12px; font-size: 13px; line-height: 1.45; }
.ksw-note-ok { color: #6EE7B7; }
.ksw-note-warn { color: #FCD34D; }
.ksw-note:not(.ksw-note-ok):not(.ksw-note-warn) { color: rgba(255, 255, 255, .7); }
.ksw-cta { margin-top: 4px; }
.ksw-next { margin: 14px 0 0; font-size: 13px; color: rgba(255, 255, 255, .6); }
.ksw-next b { color: #fff; font-variant-numeric: tabular-nums; }

/* confetti */
.ksw-confetti { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 1000000; pointer-events: none; }

/* ------------------------------------------------------------ floating */
.ksw-fab {
	position: fixed; bottom: calc(22px + max(var(--ksw-safe-bottom, 0px), env(safe-area-inset-bottom, 0px))); left: 22px; z-index: 999980;
	display: flex; align-items: center; gap: 0;
	padding: 0; border: 0; background: none; cursor: pointer;
	transform: translateY(120px) scale(.6); opacity: 0;
	transition: transform .7s var(--ksw-ease), opacity .4s, bottom .4s var(--ksw-ease);
	font-family: var(--ksw-font);
}
.ksw-fab-right .ksw-fab { left: auto; right: 22px; flex-direction: row-reverse; }
.ksw-fab.ksw-fab-in { transform: none; opacity: 1; }
.ksw-has-bar .ksw-fab { bottom: calc(92px + max(var(--ksw-safe-bottom, 0px), env(safe-area-inset-bottom, 0px))); }
.ksw[data-state="open"] .ksw-fab { opacity: 0; pointer-events: none; }
.ksw-fab-wheel {
	position: relative; z-index: 2; width: 62px; height: 62px; border-radius: 50%;
	border: 4px solid var(--ksw-rim);
	box-shadow: 0 10px 24px -4px rgba(0, 0, 0, .45), inset 0 0 0 2px rgba(0, 0, 0, .15);
	animation: ksw-rot 9s linear infinite;
}
.ksw-fab:hover .ksw-fab-wheel { animation-duration: 1.4s; }
.ksw-fab-hub { position: absolute; left: 50%; top: 50%; width: 16px; height: 16px; margin: -8px 0 0 -8px; border-radius: 50%; background: var(--ksw-rim); box-shadow: 0 0 0 3px #fff; }
.ksw-fab-pin {
	position: absolute; z-index: 3; left: 31px; top: -6px; width: 0; height: 0; margin-left: -7px;
	border-left: 7px solid transparent; border-right: 7px solid transparent; border-top: 13px solid #fff;
	filter: drop-shadow(0 2px 2px rgba(0, 0, 0, .4));
}
.ksw-fab-right .ksw-fab-pin { left: auto; right: 31px; margin: 0 -7px 0 0; }
.ksw-fab-ring { position: absolute; z-index: 1; left: 0; top: 0; width: 62px; height: 62px; border-radius: 50%; animation: ksw-ring 2.2s ease-out infinite; }
.ksw-fab-right .ksw-fab-ring { left: auto; right: 0; }
@keyframes ksw-ring { 0% { box-shadow: 0 0 0 0 rgba(251, 191, 36, .7); } 100% { box-shadow: 0 0 0 22px rgba(251, 191, 36, 0); } }
.ksw-fab-label {
	position: relative; z-index: 1; margin-left: -14px; padding: 10px 16px 10px 24px;
	border-radius: 0 99px 99px 0; white-space: nowrap;
	font-size: 14px; font-weight: 800; letter-spacing: .02em; color: #fff;
	background: linear-gradient(135deg, var(--ksw-primary), #DB2777);
	box-shadow: 0 10px 24px -6px rgba(124, 58, 237, .7);
}
.ksw-fab-right .ksw-fab-label { margin: 0 -14px 0 0; padding: 10px 24px 10px 16px; border-radius: 99px 0 0 99px; }
.ksw-fab-won .ksw-fab-label { background: linear-gradient(135deg, #059669, #10B981); }
.ksw-fab-wait .ksw-fab-ring { display: none; }
.ksw-fab-wait .ksw-fab-wheel { animation-duration: 30s; filter: saturate(.6); }
.ksw-fab:not(.ksw-fab-wait).ksw-fab-in { animation: ksw-fab-hop 5s ease-in-out 3s infinite; }
@keyframes ksw-fab-hop { 0%, 86%, 100% { transform: none; } 90% { transform: translateY(-10px); } 94% { transform: translateY(0); } 97% { transform: translateY(-4px); } }

/* ------------------------------------------------------------ coupon bar */
.ksw-bar {
	position: fixed; left: 50%; bottom: calc(18px + max(var(--ksw-safe-bottom, 0px), env(safe-area-inset-bottom, 0px))); z-index: 999985;
	display: flex; align-items: center; gap: 12px;
	width: max-content; max-width: calc(100vw - 24px);
	padding: 8px 8px 8px 14px; border-radius: 18px;
	color: #fff; font: 500 14px/1.3 var(--ksw-font);
	background: linear-gradient(135deg, rgba(22, 10, 46, .96), rgba(76, 29, 149, .96));
	border: 1px solid rgba(255, 255, 255, .16);
	box-shadow: 0 18px 40px -10px rgba(0, 0, 0, .55);
	-webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
	transform: translate(-50%, 140%); transition: transform .6s var(--ksw-ease);
}
.ksw-bar.ksw-bar-in { transform: translate(-50%, 0); }
.ksw[data-state="open"] .ksw-bar { transform: translate(-50%, 140%); }
.ksw-bar-ico { font-size: 22px; line-height: 1; }
.ksw-bar-txt { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ksw-bar-txt b { font-weight: 800; }
.ksw-bar-cd { color: rgba(255, 255, 255, .75); }
.ksw-bar-cd b { color: var(--ksw-accent); font-variant-numeric: tabular-nums; }
.ksw-bar-code {
	flex: none; height: 36px; padding: 0 12px; border-radius: 11px; cursor: pointer;
	font: 800 13.5px/1 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; letter-spacing: .06em;
	color: #2A1300; background: var(--ksw-accent); border: 0;
}
.ksw-bar-code.ksw-copied { background: #34D399; font-family: var(--ksw-font); }
.ksw-bar-x { flex: none; width: 30px; height: 30px; border-radius: 50%; border: 0; cursor: pointer; font-size: 20px; line-height: 1; color: rgba(255, 255, 255, .7); background: rgba(255, 255, 255, .08); }
.ksw-bar-x:hover { background: rgba(255, 255, 255, .18); color: #fff; }

/* ----------------------------------------------- product page button */
.ksw-pdp { margin: 14px 0 6px; font-family: var(--ksw-font, inherit); clear: both; }
.ksw-pdp *, .ksw-cta-banner * { box-sizing: border-box; }
.ksw-pdp-btn {
	position: relative; overflow: hidden; isolation: isolate;
	display: flex; align-items: center; gap: 14px; width: 100%; max-width: 520px; margin: 0;
	padding: 12px 14px 12px 12px; border: 0; border-radius: 18px; cursor: pointer; text-align: left;
	color: #fff; font-family: inherit;
	background: linear-gradient(120deg, var(--ksw-bg1, #160A2E), var(--ksw-bg2, #4C1D95) 55%, #9D174D);
	box-shadow: 0 12px 28px -12px rgba(76, 29, 149, .75), inset 0 1px 0 rgba(255, 255, 255, .15);
	transition: transform .2s cubic-bezier(.2, .9, .25, 1.2), box-shadow .2s;
}
.ksw-pdp-btn::after {
	content: ""; position: absolute; inset: 0; z-index: -1;
	background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, .22) 50%, transparent 65%);
	transform: translateX(-120%); animation: ksw-shine 3.6s ease-in-out infinite;
}
.ksw-pdp-btn:hover { transform: translateY(-2px); box-shadow: 0 16px 34px -12px rgba(76, 29, 149, .9); }
.ksw-pdp-wheel, .ksw-cta-wheel { position: relative; flex: none; width: 46px; height: 46px; border-radius: 50%; border: 3px solid var(--ksw-rim, #F5B82E); box-shadow: 0 4px 10px rgba(0, 0, 0, .35); }
.ksw-pdp-wheel i, .ksw-cta-wheel i { position: absolute; inset: 0; border-radius: 50%; background: conic-gradient(#7C3AED, #DB2777, #EA580C, #D97706, #059669, #2563EB, #7C3AED); animation: ksw-rot 6s linear infinite; }
.ksw-pdp-wheel::after, .ksw-cta-wheel::after { content: ""; position: absolute; left: 50%; top: 50%; width: 12px; height: 12px; margin: -6px 0 0 -6px; border-radius: 50%; background: var(--ksw-rim, #F5B82E); box-shadow: 0 0 0 2px #fff; }
.ksw-pdp-btn:hover .ksw-pdp-wheel i { animation-duration: .9s; }
.ksw-pdp-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.ksw-pdp-txt strong { font-size: 15.5px; font-weight: 800; line-height: 1.25; color: #fff; }
.ksw-pdp-txt small { font-size: 12.5px; line-height: 1.35; color: rgba(255, 255, 255, .78); }
.ksw-pdp-go {
	flex: none; padding: 9px 14px; border-radius: 12px;
	font-size: 13px; font-weight: 900; letter-spacing: .1em; color: #2A1300;
	background: linear-gradient(135deg, #FFE27A, var(--ksw-accent, #FBBF24) 45%, #F59E0B);
	box-shadow: 0 6px 16px -6px rgba(245, 158, 11, .9);
}
.ksw-pdp-won .ksw-pdp-btn, .ksw-pdp-btn.ksw-pdp-won { background: linear-gradient(120deg, #064E3B, #059669 60%, #10B981); }
.single_add_to_cart_button.ksw-pulse { animation: ksw-atc 1s ease-in-out 4; }
@keyframes ksw-atc { 0%, 100% { box-shadow: 0 0 0 0 rgba(124, 58, 237, .7); transform: scale(1); } 50% { box-shadow: 0 0 0 12px rgba(124, 58, 237, 0); transform: scale(1.05); } }

/* ------------------------------------------ cart / checkout banner */
.ksw-cta-banner {
	display: flex; align-items: center; gap: 14px; margin: 0 0 22px; padding: 14px 16px;
	border-radius: 18px; color: #fff; font-family: var(--ksw-font, inherit); line-height: 1.4;
	background: linear-gradient(120deg, var(--ksw-bg1, #160A2E), var(--ksw-bg2, #4C1D95) 60%, #9D174D);
	box-shadow: 0 14px 30px -16px rgba(76, 29, 149, .8);
	animation: ksw-up .6s cubic-bezier(.2, .9, .25, 1.15) both;
}
.ksw-cta-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.ksw-cta-txt strong { font-size: 15.5px; font-weight: 800; color: #fff; }
.ksw-cta-txt span { font-size: 13px; color: rgba(255, 255, 255, .8); }
.ksw-cta-bar { display: block; height: 8px; margin-top: 6px; border-radius: 9px; background: rgba(255, 255, 255, .18); overflow: hidden; }
.ksw-cta-bar i { display: block; height: 100%; border-radius: 9px; background: linear-gradient(90deg, #FFE27A, var(--ksw-accent, #FBBF24)); transition: width .6s; }
.ksw-cta-btn {
	flex: none; display: inline-flex; align-items: center; padding: 11px 16px; border: 0; border-radius: 12px; cursor: pointer;
	font: 900 13px/1 var(--ksw-font, inherit); letter-spacing: .08em; color: #2A1300 !important; text-decoration: none !important; white-space: nowrap;
	background: linear-gradient(135deg, #FFE27A, var(--ksw-accent, #FBBF24) 45%, #F59E0B);
	box-shadow: 0 6px 16px -6px rgba(245, 158, 11, .9);
	transition: transform .2s;
}
.ksw-cta-btn:hover { transform: translateY(-2px); }
/* Themes (Ecomus included) restyle every <button>; keep ours bold and on-brand. */
.ksw-cta-banner .ksw-cta-btn, .ksw-pdp .ksw-pdp-btn { font-family: inherit !important; text-transform: none !important; min-height: 0 !important; line-height: 1.2 !important; }
.ksw-cta-banner .ksw-cta-btn { font-weight: 900 !important; font-size: 13px !important; letter-spacing: .08em !important; color: #2A1300 !important; border: 0 !important; }
.ksw-pdp .ksw-pdp-btn { font-weight: 400 !important; letter-spacing: normal !important; border: 0 !important; height: auto !important; }
.ksw-cta-ok { background: linear-gradient(120deg, #064E3B, #059669 60%, #10B981); }
.ksw-cta-todo { background: linear-gradient(120deg, #7C2D12, #C2410C 55%, #EA580C); }
@media (max-width: 600px) {
	.ksw-cta-banner { flex-wrap: wrap; }
	.ksw-cta-btn { width: 100%; justify-content: center; }
	.ksw-pdp-go { display: none; }
}

/* shortcode button */
.ksw-inline-btn {
	display: inline-flex; align-items: center; gap: 8px; padding: 14px 26px; border: 0; border-radius: 14px; cursor: pointer;
	font: 800 16px/1 inherit; letter-spacing: .04em; color: #2A1300;
	background: linear-gradient(135deg, #FFE27A, #FBBF24 45%, #F59E0B);
	box-shadow: 0 10px 26px -8px rgba(245, 158, 11, .8);
	transition: transform .2s;
}
.ksw-inline-btn:hover { transform: translateY(-2px); }

@media (min-width: 768px) {
	.ksw-card { max-height: calc(100vh - 40px); overflow-y: auto; scrollbar-width: thin; }
}
@media (min-width: 768px) and (max-height: 680px) {
	.ksw-wheel-mount { max-width: 360px; }
	.ksw-stage { padding-top: 24px; padding-bottom: 24px; }
	.ksw-panel { min-height: 0; padding-top: 30px; padding-bottom: 26px; }
	.ksw-sub { margin-bottom: 16px; }
}

/* ---------------------------------------------------------------- mobile */
@media (max-width: 767px) {
	.ksw-modal { padding: 0; align-items: flex-end; }
	.ksw-shell { transform: translateY(100%); opacity: 1; transition: transform .6s cubic-bezier(.2, .9, .3, 1); }
	.ksw[data-state="closing"] .ksw-shell { transform: translateY(100%); opacity: 1; }
	.ksw-card {
		grid-template-columns: 1fr; max-height: 94vh; max-height: 94dvh; overflow-y: auto; overscroll-behavior: contain;
		border-radius: 26px 26px 0 0;
	}
	.ksw-close { top: 12px; right: 12px; background: rgba(20, 8, 40, .55); }
	.ksw-stage { padding: 30px 26px 0; }
	.ksw-wheel-mount { max-width: min(78vw, 330px); }
	.ksw-floor { bottom: -8px; }
	.ksw-panel { padding: 16px 22px 26px; min-height: 0; }
	.ksw-title { font-size: 28px; margin-top: 10px; text-align: center; }
	.ksw-view-form, .ksw-view-login { text-align: center; }
	.ksw-sub { font-size: 14.5px; margin-bottom: 16px; }
	.ksw .ksw-field input { height: 50px; font-size: 16px; }
	.ksw-fab { bottom: calc(14px + max(var(--ksw-safe-bottom, 0px), env(safe-area-inset-bottom, 0px))); left: 12px; }
	.ksw-fab-right .ksw-fab { right: 14px; }
	.ksw-fab-wheel, .ksw-fab-ring { width: 54px; height: 54px; }
	.ksw-fab-pin { left: 27px; }
	.ksw-fab-right .ksw-fab-pin { right: 27px; }
	.ksw-fab-label { font-size: 13px; padding: 8px 14px 8px 20px; }
	.ksw-bar { bottom: calc(10px + max(var(--ksw-safe-bottom, 0px), env(safe-area-inset-bottom, 0px))); gap: 8px; font-size: 13px; }
	.ksw-bar-sep, .ksw-bar-cd > span { display: none; }
	.ksw-has-bar .ksw-fab { bottom: calc(78px + max(var(--ksw-safe-bottom, 0px), env(safe-area-inset-bottom, 0px))); }
	.ksw-code-value { font-size: 19px; }
}
@media (max-width: 380px) {
	.ksw-bar-txt > b { display: none; }
}

@media (prefers-reduced-motion: reduce) {
	.ksw *, .ksw *::before, .ksw *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
	.ksw-wheel-mount { transition: opacity .3s; transform: none; }
}
