/* KatCanDo store modal, draw widget and claim popup. */
.kcd-store {
	--kcd-accent: #6d3fd8;
	--kcd-accent-ink: #fff;
	border: 0;
	border-radius: 18px;
	padding: 0;
	width: min(440px, calc(100vw - 24px));
	max-height: calc(100dvh - 24px);
	color: #1d1b26;
	background: #fff;
	box-shadow: 0 24px 64px rgba(20, 10, 50, 0.35);
	font: 16px/1.5 system-ui, -apple-system, "Segoe UI", sans-serif;
}
.kcd-store::backdrop {
	background: rgba(15, 10, 30, 0.55);
	backdrop-filter: blur(2px);
}
.kcd-store--fallback {
	position: fixed;
	inset: 0;
	margin: auto;
	z-index: 100000;
	display: none;
	height: fit-content;
}
.kcd-store--fallback.kcd-store--open,
.kcd-store--fallback[open] {
	display: block;
}
.kcd-store__inner {
	position: relative;
	padding: 28px 24px 20px;
	overflow: auto;
}
.kcd-store__close {
	position: absolute;
	top: 10px;
	right: 12px;
	width: 36px;
	height: 36px;
	border: 0;
	border-radius: 50%;
	background: transparent;
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
	color: inherit;
}
.kcd-store__close:hover,
.kcd-store__close:focus-visible {
	background: #f0edf8;
}
.kcd-store__title {
	margin: 0 0 6px;
	font-size: 1.4rem;
	line-height: 1.25;
	padding-right: 32px;
}
.kcd-store__lead {
	margin: 0 0 16px;
	color: #55506a;
}
.kcd-store__presets {
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
	margin-bottom: 12px;
}
.kcd-store__preset,
.kcd-store__pack {
	flex: 1 1 0;
	min-width: 80px;
	border: 2px solid #ddd6f3;
	border-radius: 12px;
	background: #faf9ff;
	padding: 10px 8px;
	font: inherit;
	font-weight: 600;
	cursor: pointer;
	color: inherit;
	transition: border-color 0.15s, background 0.15s, transform 0.15s;
}
.kcd-store__preset[aria-checked="true"],
.kcd-store__pack[aria-checked="true"] {
	border-color: var(--kcd-accent);
	background: #f1ebff;
}
.kcd-store__preset:focus-visible,
.kcd-store__pack:focus-visible {
	outline: 3px solid #b9a3f5;
	outline-offset: 2px;
}
.kcd-store__packs {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
	gap: 10px;
	margin-bottom: 14px;
}
.kcd-store__pack {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 2px;
}
.kcd-store__pack-tokens {
	font-size: 1.6rem;
	line-height: 1.1;
}
.kcd-store__pack-label {
	font-weight: 400;
	font-size: 0.85rem;
	color: #6b6585;
}
.kcd-store__pack-price {
	margin-top: 4px;
	color: var(--kcd-accent);
}
.kcd-store__custom {
	display: flex;
	flex-direction: column;
	gap: 4px;
	font-size: 0.9rem;
	color: #55506a;
}
.kcd-store__custom input {
	font: inherit;
	font-size: 1.05rem;
	padding: 8px 10px;
	border: 2px solid #ddd6f3;
	border-radius: 10px;
	color: #1d1b26;
}
.kcd-store__preview {
	margin: 10px 0 4px;
	font-weight: 700;
	color: var(--kcd-accent);
}
.kcd-store__preview[data-error="1"] {
	color: #b3261e;
}
.kcd-store__note,
.kcd-store__legal {
	font-size: 0.82rem;
	color: #6b6585;
	margin: 6px 0;
}
.kcd-store__legal a {
	color: inherit;
}
.kcd-store__paypal {
	min-height: 48px;
	margin: 14px 0 6px;
}
.kcd-store__msg:empty {
	display: none;
}
.kcd-store__msg {
	margin: 8px 0;
	padding: 8px 10px;
	border-radius: 8px;
	background: #f3f1f9;
	font-size: 0.9rem;
}
.kcd-store__msg[data-kind="error"] {
	background: #fdecea;
	color: #8c1d18;
}
.kcd-store__cta,
.kcd-draw__btn,
.kcd-store-btn {
	display: inline-block;
	border: 0;
	border-radius: 999px;
	padding: 11px 20px;
	background: var(--kcd-accent, #6d3fd8);
	color: #fff;
	font: inherit;
	font-weight: 700;
	text-decoration: none;
	cursor: pointer;
}
.kcd-store__cta:hover,
.kcd-draw__btn:hover,
.kcd-store-btn:hover {
	filter: brightness(1.08);
	color: #fff;
}
.kcd-store__guest {
	text-align: center;
	padding: 8px 0 12px;
}
.kcd-store__success {
	text-align: center;
}
.kcd-store__big {
	font-size: 1.5rem;
	font-weight: 800;
	margin: 6px 0;
}

/* Claim popup */
.kcd-claim .kcd-store__inner {
	text-align: center;
}
.kcd-claim__prize {
	margin: 4px auto 10px;
	width: 96px;
	height: 96px;
	display: grid;
	place-items: center;
	border-radius: 24px;
	background: radial-gradient(circle at 50% 35%, #fff6cf, #ffd36e);
	box-shadow: 0 0 0 4px #ffe9a8, 0 10px 24px rgba(180, 120, 0, 0.3);
	animation: kcd-pop 0.5s cubic-bezier(0.2, 1.4, 0.4, 1);
}
.kcd-claim__emoji {
	font-size: 56px;
	line-height: 1;
}
.kcd-claim__img {
	max-width: 80px;
	max-height: 80px;
	border-radius: 14px;
}
.kcd-claim__actions {
	display: flex;
	gap: 12px;
	justify-content: center;
	align-items: center;
}
@keyframes kcd-pop {
	from {
		transform: scale(0.4);
		opacity: 0;
	}
}
@media (prefers-reduced-motion: reduce) {
	.kcd-claim__prize {
		animation: none;
	}
}

/* Draw widget */
.kcd-draw {
	border: 1px solid #e3def2;
	border-radius: 16px;
	padding: 20px;
	margin: 1.5em 0;
	background: #fcfbff;
	color: #1d1b26;
}
.kcd-draw__title {
	margin: 0 0 4px;
}
.kcd-draw__ends {
	margin: 0 0 12px;
	color: #55506a;
	font-size: 0.95rem;
}
.kcd-draw__prizes {
	list-style: none;
	padding: 0;
	margin: 0 0 12px;
	display: grid;
	gap: 6px;
}
.kcd-draw__prizes li {
	display: flex;
	align-items: center;
	gap: 10px;
}
.kcd-prize-emoji {
	font-size: 28px;
	width: 40px;
	text-align: center;
}
.kcd-prize-img {
	border-radius: 8px;
	object-fit: cover;
}
.kcd-draw__status:empty {
	display: none;
}
.kcd-draw__status {
	margin: 8px 0;
	font-weight: 700;
	color: #23733a;
}
.kcd-draw__status[data-kind="error"] {
	color: #b3261e;
}
.kcd-draw__form {
	display: grid;
	gap: 10px;
	justify-items: start;
}
.kcd-draw__country {
	display: grid;
	gap: 4px;
}
.kcd-draw__country select {
	font: inherit;
	padding: 6px 8px;
	border-radius: 8px;
}
.kcd-draw__amoe {
	margin-top: 6px;
	padding: 10px 12px;
	border-left: 4px solid #b9a3f5;
	background: #f5f2fd;
	border-radius: 0 10px 10px 0;
	font-size: 0.92rem;
}
.kcd-draw__amoe p {
	margin: 4px 0;
}
.kcd-draw__link {
	background: none;
	border: 0;
	padding: 0;
	font: inherit;
	color: var(--kcd-accent, #6d3fd8);
	text-decoration: underline;
	cursor: pointer;
}
.kcd-draw__fair,
.kcd-draw__last details {
	margin-top: 12px;
	font-size: 0.9rem;
}
.kcd-draw__fair code,
.kcd-draw__last code {
	word-break: break-all;
	font-size: 0.8rem;
}
.kcd-draw__last {
	margin-top: 16px;
	padding-top: 12px;
	border-top: 1px dashed #d8d1ee;
}
.kcd-draw__last h4 {
	margin: 0 0 6px;
}
.kcd-rules h3 {
	margin-top: 1.4em;
}
