/* ===== Liquid-metal CTA buttons (liquid-button.js wraps the buttons) =====
   .lq-wrap  — the pill: chrome rim (shader canvas) + depth shadow
   .lq-shader — WebGL liquid metal; a static metal gradient until it mounts
   .lq-core  — the dark inner pill, inset 2px, sinks when pressed
   .lq-btn   — the original button, made transparent, drawn on top
   The metal is the same object on both themes, so colours here are fixed. */
.lq-wrap {
	position: relative;
	display: inline-flex;
	vertical-align: middle;
	flex: none;
	border-radius: 100px;
	isolation: isolate;
	box-shadow:
		0 0 0 1px rgba(0, 0, 0, 0.3),
		0 20px 12px rgba(0, 0, 0, 0.06),
		0 9px 9px rgba(0, 0, 0, 0.1),
		0 2px 5px rgba(0, 0, 0, 0.15);
	transition:
		box-shadow 0.15s cubic-bezier(0.4, 0, 0.2, 1),
		transform 0.06s linear; /* short: the hover spring sets it every frame */
}
.lq-wrap:hover {
	box-shadow:
		0 0 0 1px rgba(0, 0, 0, 0.4),
		0 12px 6px rgba(0, 0, 0, 0.05),
		0 8px 5px rgba(0, 0, 0, 0.1),
		0 4px 4px rgba(0, 0, 0, 0.15),
		0 1px 2px rgba(0, 0, 0, 0.2);
}
/* Hover (liquid-button.js): --lq-bx/--lq-by is the spring pull toward the
   cursor, --lq-lx/--lq-ly where the cursor is, --lq-li how close (0–1). */
.lq-wrap {
	transform: translate(var(--lq-bx, 0px), var(--lq-by, 0px));
}
.lq-wrap::before {
	content: "";
	position: absolute;
	inset: -10px;
	z-index: -1;
	border-radius: 100px;
	background: radial-gradient(90px circle at calc(var(--lq-lx, 50%) + 10px) calc(var(--lq-ly, 50%) + 10px), rgba(214, 222, 255, 0.42), rgba(214, 222, 255, 0) 70%);
	filter: blur(8px);
	opacity: var(--lq-li, 0);
	pointer-events: none;
}
.lq-light {
	position: absolute;
	inset: 0;
	z-index: 0;
	border-radius: 100px;
	background: radial-gradient(46px circle at var(--lq-lx, 50%) var(--lq-ly, 50%), rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0) 72%);
	mix-blend-mode: screen;
	opacity: var(--lq-li, 0);
	pointer-events: none;
}
.lq-wrap:active {
	transform: translate(var(--lq-bx, 0px), calc(var(--lq-by, 0px) + 1px)) scale(0.98);
	box-shadow:
		0 0 0 1px rgba(0, 0, 0, 0.5),
		0 1px 2px rgba(0, 0, 0, 0.3);
}
.lq-wrap.lq-full {
	display: flex;
	width: 100%;
}
.lq-wrap.lq-grow {
	flex: 1 1 auto;
}
.lq-grow .lq-btn {
	width: 100%;
}
.lq-wrap[hidden] {
	display: none;
}
.lq-wrap.lq-disabled {
	opacity: 0.5;
	pointer-events: none;
}
.lq-shader {
	position: absolute;
	inset: 0;
	z-index: 0;
	border-radius: 100px;
	overflow: hidden;
	background: linear-gradient(135deg, #b9b9b9, #4a4a4a 38%, #d6d6d6 58%, #5a5a5a 100%);
}
.lq-shader canvas {
	position: absolute !important;
	inset: 0;
	width: 100% !important;
	height: 100% !important;
	display: block !important;
	border-radius: 100px;
}
.lq-core {
	position: absolute;
	inset: 2px;
	z-index: 1;
	border-radius: 100px;
	background:
		radial-gradient(70px circle at var(--lq-lx, 50%) var(--lq-ly, -60px), rgba(255, 255, 255, calc(0.1 * var(--lq-li, 0))), rgba(255, 255, 255, 0) 70%),
		linear-gradient(180deg, #202020 0%, #000000 100%);
	transition: box-shadow 0.15s cubic-bezier(0.4, 0, 0.2, 1);
}
.lq-wrap:active .lq-core {
	box-shadow:
		inset 0 2px 4px rgba(0, 0, 0, 0.4),
		inset 0 1px 2px rgba(0, 0, 0, 0.3);
}
/* The button keeps its size, text and handlers; only its own paint goes. */
.lq-btn,
.lq-btn:hover,
.lq-btn:disabled {
	position: relative;
	z-index: 2;
	min-height: 44px;
	border: 0 !important;
	border-radius: 100px !important;
	background: transparent !important;
	box-shadow: none !important;
	color: #e4e4e4 !important;
	text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
	overflow: hidden;
	filter: none !important;
	transform: none !important;
	opacity: 1 !important;
}
.lq-full .lq-btn {
	width: 100%;
}
/* Optical centring for text labels: Satoshi's ink sits low in its line box,
   so a flex-centred label looks a pixel or two south. Icon circles are exempt. */
.lq-btn:not(.fh-act) {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	line-height: 1;
	padding-top: 0 !important;
	padding-bottom: 2px !important;
}
.lq-full .lq-btn:not(.fh-act),
.lq-grow .lq-btn:not(.fh-act) {
	display: flex;
}
.lq-btn:focus-visible {
	outline: 2px solid var(--ring);
	outline-offset: 3px;
}
.lq-ripple {
	position: absolute;
	width: 20px;
	height: 20px;
	border-radius: 50%;
	background: radial-gradient(circle, rgba(255, 255, 255, 0.4) 0%, rgba(255, 255, 255, 0) 70%);
	pointer-events: none;
	transform: translate(-50%, -50%) scale(0);
	animation: lq-ripple 0.6s ease-out forwards;
}
@keyframes lq-ripple {
	from {
		transform: translate(-50%, -50%) scale(0);
		opacity: 0.6;
	}
	to {
		transform: translate(-50%, -50%) scale(4);
		opacity: 0;
	}
}
@media (prefers-reduced-motion: reduce) {
	.lq-wrap,
	.lq-core {
		transition: none;
	}
	.lq-wrap::before,
	.lq-light {
		display: none;
	}
	.lq-ripple {
		display: none;
	}
}
