/**
 * KS Referral & Treasure Rewards — front-end styles.
 * Fonts: Fraunces (headings) + Plus Jakarta Sans (body). Mobile-first, RTL-safe.
 */

.ksref-map {
	--ksref-accent: #c8a24b;
	--ksref-ink: #211c2b;
	--ksref-muted: #6b6577;
	--ksref-line: #e7e3dd;
	--ksref-card: #ffffff;
	font-family: "Plus Jakarta Sans", system-ui, -apple-system, sans-serif;
	color: var(--ksref-ink);
	max-width: 900px;
	margin: 0 auto;
}

.ksref-map *,
.ksref-modal * {
	box-sizing: border-box;
}

.ksref-map__head {
	text-align: center;
	margin-bottom: 22px;
}

.ksref-map__title {
	font-family: "Fraunces", Georgia, serif;
	font-size: clamp(26px, 5vw, 38px);
	font-weight: 700;
	margin: 0 0 6px;
}

.ksref-map__sub {
	color: var(--ksref-muted);
	margin: 0;
}

/* Code card */
.ksref-code-card {
	background: linear-gradient(150deg, #211c2b, #3a2f49);
	color: #fff;
	border-radius: 18px;
	padding: 22px;
	text-align: center;
	box-shadow: 0 12px 30px -12px rgba(33, 28, 43, 0.6);
}

.ksref-code-card__label {
	text-transform: uppercase;
	letter-spacing: 0.08em;
	font-size: 11px;
	opacity: 0.7;
}

.ksref-code-card__code {
	font-family: "Fraunces", serif;
	font-size: clamp(30px, 7vw, 46px);
	font-weight: 700;
	letter-spacing: 0.04em;
	color: var(--ksref-accent);
	margin: 4px 0 12px;
}

.ksref-code-card__link input {
	width: 100%;
	max-width: 360px;
	text-align: center;
	border: 1px solid rgba(255, 255, 255, 0.2);
	background: rgba(255, 255, 255, 0.08);
	color: #fff;
	border-radius: 10px;
	padding: 9px 12px;
	font-size: 13px;
}

.ksref-share {
	display: flex;
	gap: 10px;
	justify-content: center;
	flex-wrap: wrap;
	margin-top: 16px;
}

.ksref-btn {
	border: none;
	border-radius: 999px;
	padding: 10px 18px;
	font-weight: 700;
	font-size: 13px;
	font-family: inherit;
	cursor: pointer;
	text-decoration: none;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	background: #fff;
	color: #211c2b;
	transition: transform 0.12s ease, box-shadow 0.12s ease;
}

.ksref-btn:hover {
	transform: translateY(-1px);
}

.ksref-btn--primary {
	background: var(--ksref-accent);
	color: #211c2b;
}

.ksref-btn--wa {
	background: #25d366;
	color: #06371a;
}

.ksref-btn--ig {
	background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
	color: #fff;
}

/* Next tier progress */
.ksref-next {
	margin: 24px 0 10px;
	text-align: center;
}

.ksref-next__text {
	font-size: 15px;
	margin-bottom: 10px;
}

.ksref-progress {
	height: 14px;
	border-radius: 999px;
	background: var(--ksref-line);
	overflow: hidden;
	max-width: 460px;
	margin: 0 auto;
}

.ksref-progress__bar {
	display: block;
	height: 100%;
	border-radius: 999px;
	background: linear-gradient(90deg, var(--ksref-accent), #e6c17a);
	transition: width 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.ksref-next--max {
	font-family: "Fraunces", serif;
	font-size: 18px;
	color: var(--ksref-accent);
}

/* Tier list */
.ksref-tiers {
	list-style: none;
	margin: 24px 0;
	padding: 0;
	display: grid;
	gap: 14px;
}

.ksref-map--grid .ksref-tiers {
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}

.ksref-tier {
	--tier-accent: #c8a24b;
	display: flex;
	gap: 14px;
	align-items: center;
	background: var(--ksref-card);
	border: 1px solid var(--ksref-line);
	border-left: 4px solid var(--tier-accent);
	border-radius: 14px;
	padding: 14px;
	position: relative;
	transition: transform 0.15s ease;
}

.ksref-tier--unlocked {
	box-shadow: 0 0 0 1px var(--tier-accent), 0 10px 26px -16px var(--tier-accent);
}

.ksref-tier--locked {
	opacity: 0.6;
	filter: grayscale(0.55);
}

/* Winding path: alternate offsets to suggest a trail */
.ksref-map--winding_path .ksref-tier:nth-child(even) {
	margin-inline-start: 36px;
}

.ksref-map--winding_path .ksref-tier:nth-child(odd) {
	margin-inline-end: 36px;
}

.ksref-tier__media {
	position: relative;
	width: 64px;
	height: 64px;
	flex: 0 0 64px;
	border-radius: 12px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: linear-gradient(160deg, var(--tier-accent), color-mix(in srgb, var(--tier-accent) 55%, #000));
	color: #fff;
	font-size: 30px;
}

.ksref-tier__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	border-radius: 12px;
}

.ksref-tier__lock {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(0, 0, 0, 0.35);
	border-radius: 12px;
	font-size: 22px;
}

.ksref-tier__label {
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	color: var(--tier-accent);
}

.ksref-tier__title {
	font-family: "Fraunces", serif;
	font-size: 17px;
	font-weight: 600;
}

.ksref-tier__desc {
	font-size: 13px;
	color: var(--ksref-muted);
	margin: 2px 0;
}

.ksref-tier__meta {
	display: flex;
	align-items: center;
	gap: 10px;
	font-size: 12px;
	color: var(--ksref-muted);
	margin-top: 4px;
}

.ksref-badge {
	font-weight: 700;
	font-size: 11px;
	padding: 2px 9px;
	border-radius: 999px;
}

.ksref-badge--ready {
	background: #fff4d6;
	color: #8a6400;
}

.ksref-badge--claimed {
	background: #e7f6ec;
	color: #1c7a3e;
}

/* Join / prompt cards */
.ksref-map--join,
.ksref-map--prompt {
	text-align: center;
	background: var(--ksref-card);
	border: 1px solid var(--ksref-line);
	border-radius: 16px;
	padding: 34px 22px;
}

/* Checkout field */
.ksref-checkout-field {
	border: 1px dashed var(--ksref-line);
	border-radius: 12px;
	padding: 14px;
	margin: 14px 0;
	font-family: "Plus Jakarta Sans", sans-serif;
}

.ksref-checkout-label {
	font-weight: 700;
	margin: 0 0 8px;
}

.ksref-checkout-row {
	display: flex;
	gap: 8px;
}

.ksref-checkout-row input {
	flex: 1;
	padding: 9px 11px;
	border: 1px solid var(--ksref-line);
	border-radius: 9px;
}

.ksref-checkout-msg {
	font-size: 13px;
	color: #1c7a3e;
	margin: 8px 0 0;
}

.ksref-checkout-msg.is-error {
	color: #b4232a;
}

/* Modal popup */
.ksref-modal {
	position: fixed;
	inset: 0;
	z-index: 99999;
	background: rgba(15, 11, 22, 0.65);
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
	opacity: 0;
	transition: opacity 0.25s ease;
	font-family: "Plus Jakarta Sans", sans-serif;
}

.ksref-modal.is-open {
	opacity: 1;
}

.ksref-modal__box {
	--ksref-accent: #c8a24b;
	position: relative;
	width: min(620px, 100%);
	max-height: 88vh;
	overflow-y: auto;
	border-radius: 20px;
	padding: 28px;
	color: #fff;
	box-shadow: 0 30px 80px -20px rgba(0, 0, 0, 0.7);
	transform: translateY(14px) scale(0.98);
	transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

.ksref-modal.is-open .ksref-modal__box {
	transform: translateY(0) scale(1);
}

.ksref-modal__close {
	position: absolute;
	top: 14px;
	inset-inline-end: 16px;
	background: rgba(255, 255, 255, 0.15);
	border: none;
	color: #fff;
	width: 34px;
	height: 34px;
	border-radius: 999px;
	font-size: 20px;
	cursor: pointer;
}

.ksref-modal__title {
	font-family: "Fraunces", serif;
	font-size: 26px;
	margin: 0 0 4px;
}

.ksref-modal__sub {
	opacity: 0.85;
	margin: 0 0 18px;
}

.ksref-modal__map {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.ksref-modal__box[data-style="grid"] .ksref-modal__map {
	display: grid;
	grid-template-columns: 1fr 1fr;
}

.kspn {
	--tier-accent: #c8a24b;
	display: flex;
	gap: 12px;
	align-items: center;
	padding: 11px;
	border-radius: 12px;
	background: rgba(255, 255, 255, 0.08);
	border-inline-start: 3px solid var(--tier-accent);
}

.kspn.is-locked {
	opacity: 0.45;
	filter: grayscale(0.6);
}

.kspn.is-unlocked {
	box-shadow: 0 0 0 1px var(--tier-accent), 0 0 18px -6px var(--tier-accent);
}

.kspn-media {
	position: relative;
	width: 48px;
	height: 48px;
	flex: 0 0 48px;
	border-radius: 10px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: linear-gradient(160deg, var(--tier-accent), color-mix(in srgb, var(--tier-accent) 55%, #000));
	font-size: 24px;
}

.kspn-media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	border-radius: 10px;
}

.kspn-lock {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(0, 0, 0, 0.4);
	border-radius: 10px;
}

.kspn-badge {
	position: absolute;
	top: -6px;
	inset-inline-end: -6px;
	font-size: 9px;
	font-weight: 700;
	background: #1c7a3e;
	color: #fff;
	padding: 2px 6px;
	border-radius: 999px;
}

.kspn-badge--ready {
	background: var(--ksref-accent, #c8a24b);
	color: #211c2b;
}

.kspn-title {
	font-weight: 700;
	font-size: 14px;
	display: block;
}

.kspn-req {
	font-size: 11px;
	opacity: 0.8;
}

/* Confetti */
.ksref-confetti {
	position: absolute;
	inset: 0;
	overflow: hidden;
	pointer-events: none;
	border-radius: 20px;
}

.ksref-confetti__bit {
	position: absolute;
	top: -12px;
	width: 9px;
	height: 14px;
	border-radius: 2px;
	animation: ksref-fall linear forwards;
}

@keyframes ksref-fall {
	to {
		transform: translateY(110%) rotate(540deg);
		opacity: 0;
	}
}

@media (prefers-reduced-motion: reduce) {
	.ksref-confetti {
		display: none;
	}
	.ksref-progress__bar,
	.ksref-modal,
	.ksref-modal__box {
		transition: none;
	}
}

@media (max-width: 600px) {
	.ksref-map--winding_path .ksref-tier {
		margin-inline: 0 !important;
	}
	.ksref-modal__box[data-style="grid"] .ksref-modal__map {
		grid-template-columns: 1fr;
	}
}

/* =====================================================================
 * TREASURE MAP THEME (map_style = treasure_map)
 * ================================================================== */
.ksref-map--treasure_map {
	--parch-bg: #ecd9ac;
	--parch-edge: #8a6a3a;
	--parch-ink: #5b3f22;
	background:
		radial-gradient(120% 90% at 50% 0%, #f3e6c4 0%, #e7d2a4 55%, #ddc18c 100%);
	border: 2px solid var(--parch-edge);
	border-radius: 18px;
	padding: 22px 18px 30px;
	box-shadow: inset 0 0 0 6px rgba(138, 106, 58, 0.18), inset 0 0 60px rgba(120, 85, 40, 0.25);
	color: var(--parch-ink);
}

.ksref-map--treasure_map .ksref-map__title,
.ksref-map--treasure_map .ksref-map__sub {
	color: var(--parch-ink);
}

.ksref-map--treasure_map .ksref-next__text,
.ksref-map--treasure_map .ksref-next--max {
	color: var(--parch-ink);
}

/* The trail */
.ksref-trail {
	position: relative;
	max-width: 760px;
	margin: 26px auto 6px;
	padding: 6px 0 30px;
}

.ksref-trail__route {
	position: absolute;
	top: 0;
	bottom: 64px;
	left: 50%;
	width: 0;
	border-left: 3px dashed var(--parch-edge);
	transform: translateX(-50%);
	opacity: 0.7;
}

.ksref-trail__node {
	position: relative;
	width: 50%;
	box-sizing: border-box;
	padding: 10px 22px;
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
}

.ksref-trail__node.is-left {
	margin-inline-end: 50%;
}

.ksref-trail__node.is-right {
	margin-inline-start: 50%;
}

/* little connector knot on the route */
.ksref-trail__node::after {
	content: "";
	position: absolute;
	top: 28px;
	width: 12px;
	height: 12px;
	border-radius: 50%;
	background: var(--parch-edge);
	box-shadow: 0 0 0 3px var(--parch-bg);
}

.ksref-trail__node.is-left::after {
	inset-inline-end: -6px;
}

.ksref-trail__node.is-right::after {
	inset-inline-start: -6px;
}

/* Chest button */
.ksref-chest {
	position: relative;
	border: none;
	background: transparent;
	cursor: pointer;
	padding: 6px;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 6px;
	transition: transform 0.18s cubic-bezier(0.22, 1, 0.36, 1);
	font-family: inherit;
}

.ksref-chest:hover,
.ksref-chest:focus-visible {
	transform: translateY(-5px) scale(1.05);
	outline: none;
}

.ksref-chest__art {
	position: relative;
	width: 92px;
	height: 78px;
	display: flex;
	align-items: flex-end;
	justify-content: center;
}

.ksref-chest__art .ksref-chest-svg {
	width: 100%;
	height: auto;
	filter: drop-shadow(0 6px 8px rgba(70, 45, 15, 0.35));
}

.ksref-chest.is-unlocked .ksref-chest__art {
	animation: ksref-bob 2.6s ease-in-out infinite;
}

.ksref-chest.is-locked .ksref-chest-svg {
	filter: grayscale(0.85) brightness(0.8);
	opacity: 0.7;
}

.ksref-chest__glow {
	position: absolute;
	inset: -10px -6px 6px;
	border-radius: 50%;
	background: radial-gradient(circle, var(--tier-accent, #c8a24b) 0%, transparent 68%);
	opacity: 0.55;
	z-index: -1;
	animation: ksref-pulse 2.2s ease-in-out infinite;
}

.ksref-chest__label {
	font-family: "Fraunces", serif;
	font-weight: 600;
	font-size: 13px;
	color: var(--parch-ink);
	letter-spacing: 0.02em;
}

.ksref-chest__name {
	font-size: 12.5px;
	font-weight: 600;
	color: #6b4a1f;
	max-width: 150px;
	line-height: 1.3;
}

.ksref-chest.is-locked .ksref-chest__name {
	opacity: 0.65;
}

.ksref-chest__badge {
	font-size: 10px;
	font-weight: 700;
	padding: 2px 8px;
	border-radius: 999px;
	text-transform: uppercase;
	letter-spacing: 0.04em;
}

.ksref-chest__badge--ready {
	background: var(--tier-accent, #c8a24b);
	color: #3a2606;
}

.ksref-chest__badge--claimed {
	background: #2f7d4f;
	color: #fff;
}

/* X marks the spot */
.ksref-trail__x {
	position: relative;
	width: 100%;
	text-align: center;
	margin-top: 8px;
}

.ksref-trail__x-mark {
	display: inline-block;
	font-family: "Fraunces", serif;
	font-weight: 700;
	font-size: 38px;
	color: #b4232a;
	transform: rotate(-8deg);
	text-shadow: 0 2px 0 rgba(120, 85, 40, 0.3);
}

.ksref-trail__x-text {
	display: block;
	font-size: 12px;
	font-style: italic;
	color: var(--parch-ink);
	opacity: 0.8;
}

.ksref-trail__hint {
	text-align: center;
	font-size: 13px;
	font-style: italic;
	color: #6b4a1f;
	margin: 4px 0 10px;
}

@keyframes ksref-bob {
	0%, 100% { transform: translateY(0); }
	50% { transform: translateY(-5px); }
}

@keyframes ksref-pulse {
	0%, 100% { opacity: 0.35; transform: scale(0.92); }
	50% { opacity: 0.65; transform: scale(1.08); }
}

/* =====================================================================
 * CHEST REVEAL MODAL
 * ================================================================== */
.ksref-reveal__box {
	--parch-ink: #5b3f22;
	position: relative;
	width: min(440px, 100%);
	background:
		radial-gradient(120% 100% at 50% 0%, #f5e9c8 0%, #e8d3a4 70%, #ddc089 100%);
	border: 2px solid #8a6a3a;
	border-radius: 20px;
	padding: 26px 24px 30px;
	text-align: center;
	color: var(--parch-ink);
	box-shadow: inset 0 0 0 6px rgba(138, 106, 58, 0.18), 0 30px 80px -20px rgba(0, 0, 0, 0.7);
	transform: translateY(16px) scale(0.96);
	transition: transform 0.32s cubic-bezier(0.22, 1, 0.36, 1);
}

.ksref-reveal.is-open .ksref-reveal__box {
	transform: translateY(0) scale(1);
}

.ksref-reveal__label {
	font-family: "Fraunces", serif;
	font-weight: 600;
	font-size: 14px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: #8a6a3a;
}

.ksref-reveal__stage {
	position: relative;
	height: 230px;
	margin: 6px 0 4px;
	display: flex;
	align-items: flex-end;
	justify-content: center;
}

.ksref-reveal__chest {
	width: 168px;
	position: relative;
	z-index: 2;
}

.ksref-reveal__chest .ksref-chest-svg {
	width: 100%;
	height: auto;
	filter: drop-shadow(0 10px 12px rgba(70, 45, 15, 0.4));
}

.ksref-reveal__prize {
	position: absolute;
	bottom: 58px;
	left: 50%;
	transform: translateX(-50%);
	z-index: 3;
	width: 190px;
	max-width: 70%;
}

.ksref-reveal.is-open .ksref-reveal__prize {
	animation: ksref-pop-out 0.7s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

.ksref-reveal__img {
	width: 100%;
	height: auto;
	border-radius: 12px;
	border: 3px solid #fff;
	box-shadow: 0 14px 28px -8px rgba(70, 45, 15, 0.6);
}

.ksref-reveal__icon {
	font-size: 90px;
	line-height: 1;
	filter: drop-shadow(0 10px 16px rgba(70, 45, 15, 0.5));
}

.ksref-reveal__lockicon {
	position: absolute;
	bottom: 96px;
	left: 50%;
	transform: translateX(-50%);
	z-index: 3;
	font-size: 44px;
	opacity: 0.85;
}

.ksref-reveal__name {
	font-family: "Fraunces", serif;
	font-weight: 700;
	font-size: 21px;
	color: #4a2f12;
	margin-top: 2px;
}

.ksref-reveal__desc {
	font-size: 13px;
	color: #6b4a1f;
	margin-top: 4px;
}

.ksref-reveal__meta {
	margin-top: 12px;
}

.ksref-reveal__status {
	display: inline-block;
	font-weight: 700;
	font-size: 13px;
	padding: 6px 16px;
	border-radius: 999px;
}

.ksref-reveal__status.is-ready {
	background: var(--ksref-accent, #c8a24b);
	color: #3a2606;
}

.ksref-reveal__status.is-claimed {
	background: #2f7d4f;
	color: #fff;
}

.ksref-reveal__locked {
	display: inline-block;
	font-weight: 600;
	font-size: 13px;
	color: #8a3a2a;
	background: rgba(180, 35, 42, 0.12);
	padding: 6px 16px;
	border-radius: 999px;
}

.ksref-reveal__spark {
	position: absolute;
	top: 40%;
	left: 50%;
	width: 10px;
	height: 10px;
	background: var(--ksref-accent, #ffe9af);
	border-radius: 50%;
	opacity: 0;
	z-index: 1;
}

.ksref-reveal.is-open .ksref-reveal__spark {
	animation: ksref-spark 0.9s ease-out both;
	animation-delay: calc(0.25s + var(--i) * 0.05s);
}

.ksref-reveal__spark:nth-child(1) { --dx: -120px; --dy: -40px; }
.ksref-reveal__spark:nth-child(2) { --dx: 110px; --dy: -50px; }
.ksref-reveal__spark:nth-child(3) { --dx: -90px; --dy: -110px; }
.ksref-reveal__spark:nth-child(4) { --dx: 90px; --dy: -100px; }
.ksref-reveal__spark:nth-child(5) { --dx: 0px; --dy: -140px; }
.ksref-reveal__spark:nth-child(6) { --dx: -150px; --dy: -80px; }
.ksref-reveal__spark:nth-child(7) { --dx: 150px; --dy: -70px; }

@keyframes ksref-pop-out {
	0% { transform: translateX(-50%) translateY(46px) scale(0.3) rotate(-10deg); opacity: 0; }
	55% { transform: translateX(-50%) translateY(-20px) scale(1.12) rotate(4deg); opacity: 1; }
	75% { transform: translateX(-50%) translateY(-6px) scale(0.97) rotate(-2deg); }
	100% { transform: translateX(-50%) translateY(-12px) scale(1) rotate(0); opacity: 1; }
}

@keyframes ksref-spark {
	0% { opacity: 0; transform: translate(-50%, -50%) scale(0.4); }
	30% { opacity: 1; }
	100% { opacity: 0; transform: translate(calc(-50% + var(--dx)), calc(-50% + var(--dy))) scale(0.8); }
}

/* =====================================================================
 * HOME-PAGE BANNER ([ks_referral_banner])
 * ================================================================== */
.ksref-banner {
	font-family: "Plus Jakarta Sans", system-ui, sans-serif;
	position: relative;
	border-radius: 20px;
	overflow: hidden;
	background:
		radial-gradient(130% 120% at 12% 0%, #f3e6c4 0%, #e7d2a4 55%, #d8bd86 100%);
	background-size: cover;
	background-position: center;
	color: #5b3f22;
	margin: 18px auto;
	max-width: 1100px;
}

.ksref-banner__frame {
	position: relative;
	display: grid;
	grid-template-columns: 1fr 280px;
	gap: 20px;
	align-items: center;
	padding: 30px 34px;
	margin: 12px;
	border: 2px dashed rgba(138, 106, 58, 0.7);
	border-radius: 14px;
}

.ksref-banner__compass {
	position: absolute;
	top: 14px;
	inset-inline-end: 16px;
	width: 58px;
	height: 58px;
	color: rgba(120, 85, 40, 0.55);
}

.ksref-banner__compass svg {
	width: 100%;
	height: 100%;
}

.ksref-banner__eyebrow {
	display: inline-block;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: #8a6a3a;
	margin-bottom: 6px;
}

.ksref-banner__title {
	font-family: "Fraunces", Georgia, serif;
	font-weight: 700;
	font-size: clamp(24px, 4vw, 40px);
	line-height: 1.05;
	margin: 0 0 8px;
	color: #4a2f12;
}

.ksref-banner__sub {
	font-size: 15px;
	max-width: 46ch;
	margin: 0 0 18px;
	color: #5b3f22;
}

.ksref-banner__actions {
	display: flex;
	align-items: center;
	gap: 14px;
	flex-wrap: wrap;
}

.ksref-banner__cta {
	background: var(--ksref-accent, #c8a24b);
	color: #3a2606;
	box-shadow: 0 8px 18px -6px rgba(120, 85, 40, 0.7);
	padding: 12px 24px;
	font-size: 15px;
}

.ksref-banner__code {
	display: inline-flex;
	flex-direction: column;
	line-height: 1.1;
}

.ksref-banner__code-label {
	font-size: 11px;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	color: #8a6a3a;
}

.ksref-banner__code-val {
	font-family: "Fraunces", serif;
	font-weight: 700;
	font-size: 20px;
	color: #4a2f12;
	background: transparent;
	border: 1px dashed #8a6a3a;
	border-radius: 8px;
	padding: 3px 10px;
	cursor: pointer;
}

.ksref-banner__trail {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: space-between;
	height: 96px;
}

.ksref-banner__trail::before {
	content: "";
	position: absolute;
	top: 50%;
	left: 0;
	right: 0;
	border-top: 3px dashed rgba(138, 106, 58, 0.7);
}

.ksref-banner__dot {
	position: relative;
	width: 12px;
	height: 12px;
	border-radius: 50%;
	background: rgba(138, 106, 58, 0.8);
}

.ksref-banner__chest {
	width: 56px;
	height: auto;
	background: transparent;
}

.ksref-banner__chest .ksref-chest-svg {
	width: 56px;
	height: auto;
	filter: drop-shadow(0 5px 7px rgba(70, 45, 15, 0.35));
}

.ksref-banner__chest--big .ksref-chest-svg {
	width: 74px;
}

.ksref-banner__chest.is-on .ksref-chest-svg {
	animation: ksref-bob 2.6s ease-in-out infinite;
}

@media (max-width: 720px) {
	.ksref-banner__frame {
		grid-template-columns: 1fr;
	}
	.ksref-banner__trail {
		height: 76px;
	}
}

@media (max-width: 600px) {
	.ksref-trail__route {
		left: 26px;
	}
	.ksref-trail__node,
	.ksref-trail__node.is-left,
	.ksref-trail__node.is-right {
		width: 100%;
		margin: 0;
		flex-direction: row;
		gap: 14px;
		text-align: start;
		padding-inline-start: 54px;
	}
	.ksref-trail__node::after {
		inset-inline-start: 20px;
		inset-inline-end: auto;
	}
	.ksref-chest {
		flex-direction: row;
		gap: 12px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.ksref-chest.is-unlocked .ksref-chest__art,
	.ksref-chest__glow,
	.ksref-banner__chest.is-on .ksref-chest-svg,
	.ksref-reveal.is-open .ksref-reveal__prize,
	.ksref-reveal.is-open .ksref-reveal__spark {
		animation: none;
	}
}
