.mws-ew-ab {
	--mws-ew-ab-fill: #000000;
	--mws-ew-ab-fill-text: #ffffff;
	--mws-ew-ab-draw: #000000;
	--mws-ew-ab-underline: #3f63d1;
	--mws-ew-ab-glow-a: #3f63d1;
	--mws-ew-ab-glow-b: #000000;
	--mws-ew-ab-press-shadow: rgba(63, 99, 209, 0.35);
	--mws-ew-ab-radius: 999px;
	--mws-ew-ab-ease: cubic-bezier(0.65, 0, 0.35, 1);
	display: block;
	line-height: 0;
}

.mws-ew-ab__btn {
	all: unset;
	box-sizing: border-box;
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	font-family: inherit;
	font-size: 14.5px;
	font-weight: 600;
	letter-spacing: 0.2px;
	line-height: 1.2;
	color: #17171a;
	background-color: #f4f3f0;
	border: 1px solid #e3e1db;
	padding: 13px 26px;
	border-radius: 999px;
	cursor: pointer;
	max-width: 100%;
	white-space: normal;
	overflow-wrap: break-word;
	word-break: break-word;
	overflow: hidden;
	isolation: isolate;
	text-decoration: none;
	vertical-align: middle;
	transition: border-color 0.25s ease, background-color 0.25s ease, color 0.25s ease, box-shadow 0.25s ease;
	-webkit-tap-highlight-color: transparent;
}

/* Sticky :hover on touch starts CSS/GSAP then clears — gate to real hover devices. */
@media (hover: hover) and (pointer: fine) {
	.mws-ew-ab__btn:hover {
		color: #ffffff;
		background-color: #171717;
		border-color: #171717;
	}
}

@media (hover: none) {
	.mws-ew-ab__btn:active,
	.mws-ew-ab__btn.is-nav-pending {
		color: #ffffff;
		background-color: #171717;
		border-color: #171717;
	}
}

.mws-ew-ab__btn:focus-visible {
	outline: 2px solid #3f63d1;
	outline-offset: 3px;
}

.mws-ew-ab__label {
	position: relative;
	z-index: 2;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: inherit;
	pointer-events: none;
	min-width: 0;
	max-width: 100%;
}

.mws-ew-ab__txt {
	position: relative;
	z-index: 2;
	pointer-events: none;
	display: inline-block;
	min-width: 0;
	overflow-wrap: break-word;
	word-break: break-word;
}

.mws-ew-ab__icon {
	position: relative;
	z-index: 2;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 16px;
	height: 16px;
	font-size: 16px;
	line-height: 1;
	pointer-events: none;
	transform-origin: 50% 50%;
}

.mws-ew-ab__icon svg,
.mws-ew-ab__svg {
	display: block;
	width: 1em;
	height: 1em;
}

/* Mirror directional glyphs only when the button itself is RTL */
.mws-ew-ab:dir(rtl) .mws-ew-ab__icon svg,
.mws-ew-ab:dir(rtl) .mws-ew-ab__arrow svg,
:is([dir="rtl"], .rtl) .mws-ew-ab__icon svg,
:is([dir="rtl"], .rtl) .mws-ew-ab__arrow svg {
	transform: scaleX(-1);
}

/* ---- Magnetic ---- */
@media (hover: hover) and (pointer: fine) {
	.mws-ew-ab__btn--magnetic:hover {
		will-change: transform;
	}
}

/* ---- Ink fill ---- */
.mws-ew-ab__btn--fill > .mws-ew-ab__label {
	z-index: 1;
}

.mws-ew-ab__fill {
	position: absolute;
	inset: 0;
	z-index: 3;
	background: var(--mws-ew-ab-fill);
	clip-path: circle(0% at 50% 50%);
	display: flex;
	align-items: center;
	justify-content: center;
	pointer-events: none;
	color: var(--mws-ew-ab-fill-text);
}

.mws-ew-ab__fill .mws-ew-ab__label,
.mws-ew-ab__fill .mws-ew-ab__txt,
.mws-ew-ab__fill .mws-ew-ab__icon {
	z-index: 1;
	color: var(--mws-ew-ab-fill-text);
}

/* ---- Border draw ---- */
.mws-ew-ab__draw-svg {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	overflow: visible;
	pointer-events: none;
	z-index: 1;
}

.mws-ew-ab__draw-rect {
	fill: none;
	stroke: var(--mws-ew-ab-draw);
	stroke-width: 1.4;
	stroke-dasharray: 100;
	stroke-dashoffset: 100;
}

/* ---- Arrow ---- */
.mws-ew-ab__arrow-track {
	position: relative;
	width: 18px;
	height: 14px;
	overflow: hidden;
	display: inline-block;
	flex-shrink: 0;
	z-index: 2;
}

.mws-ew-ab__arrow {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	color: currentColor;
}

/* ---- Perspective Flip (was Character Wave) ---- */
.mws-ew-ab__btn--split {
	overflow: hidden;
	perspective: 640px;
}

.mws-ew-ab__btn--split .mws-ew-ab__txt {
	display: inline-block;
	transform-style: preserve-3d;
}

.mws-ew-ab__btn--split .mws-ew-ab__char {
	display: inline-block;
	transform-origin: 50% 50%;
	transform-style: preserve-3d;
	backface-visibility: hidden;
}

/* ---- Marquee ---- */
.mws-ew-ab__btn--marquee {
	overflow: hidden;
	justify-content: flex-start;
}

.mws-ew-ab__marquee-mask {
	display: block;
	overflow: hidden;
	width: auto;
	max-width: 100%;
	z-index: 2;
	line-height: 1.2;
}

.mws-ew-ab__marquee-track {
	display: flex;
	flex-wrap: nowrap;
	gap: 2em;
	width: max-content;
}

.mws-ew-ab__marquee-item {
	flex: 0 0 auto;
	white-space: nowrap;
}

/* ---- Ripple ---- */
.mws-ew-ab__ripple {
	position: absolute;
	z-index: 1;
	border-radius: 50%;
	background: radial-gradient(circle, var(--mws-ew-ab-fill) 0%, transparent 70%);
	pointer-events: none;
}

/* ---- Press ---- */
@media (hover: hover) and (pointer: fine) {
	.mws-ew-ab__btn--press:hover {
		will-change: transform, box-shadow;
	}
}

/* ---- Underline ---- */
.mws-ew-ab__underline {
	position: absolute;
	left: 1.5em;
	right: 1.5em;
	bottom: 0.55em;
	height: 1.5px;
	background: var(--mws-ew-ab-underline);
	transform: scaleX(0);
	transform-origin: left center;
	z-index: 2;
	pointer-events: none;
}

:is([dir="rtl"], .rtl) .mws-ew-ab__underline,
.mws-ew-ab:dir(rtl) .mws-ew-ab__underline {
	transform-origin: right center;
}

/* ---- Swap ---- */
.mws-ew-ab__btn--swap {
	overflow: hidden;
}

.mws-ew-ab__swap-inner {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	height: 1.2em;
	overflow: hidden;
	z-index: 2;
}

.mws-ew-ab__swap-face {
	display: flex;
	align-items: center;
	justify-content: center;
	white-space: nowrap;
}

.mws-ew-ab__swap-top {
	position: relative;
}

.mws-ew-ab__swap-bottom {
	position: absolute;
	inset: 0;
}

/* ---- Glow ---- */
.mws-ew-ab__btn--glow {
	border-color: transparent;
	overflow: hidden;
	background-color: var(--mws-ew-ab-glow-a);
}

@media (hover: hover) and (pointer: fine) {
	.mws-ew-ab__btn--glow:hover {
		background-color: var(--mws-ew-ab-glow-a);
	}
}

.mws-ew-ab__glow-bg {
	position: absolute;
	left: 50%;
	top: 50%;
	width: 220%;
	height: 220%;
	min-width: 180px;
	min-height: 180px;
	aspect-ratio: 1 / 1;
	background: conic-gradient(
		from 0deg,
		var(--mws-ew-ab-glow-a),
		var(--mws-ew-ab-glow-b) 25%,
		var(--mws-ew-ab-glow-a) 50%,
		var(--mws-ew-ab-glow-b) 75%,
		var(--mws-ew-ab-glow-a)
	);
	z-index: 0;
	pointer-events: none;
}

.mws-ew-ab__glow-veil {
	position: absolute;
	inset: 1px;
	z-index: 1;
	border-radius: inherit;
	background: rgba(0, 0, 0, 0.18);
	pointer-events: none;
}

.mws-ew-ab__btn--glow .mws-ew-ab__label,
.mws-ew-ab__btn--glow .mws-ew-ab__txt {
	color: #fff;
	text-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
}

/* ---- Scramble ---- */
.mws-ew-ab__btn--scramble {
	font-variant-numeric: tabular-nums;
}

/* ---- Liquid ---- */
.mws-ew-ab__btn--liquid {
	transition: border-color 0.25s ease, background-color 0.25s ease, color 0.25s ease;
}

/* ---- Burst ---- */
.mws-ew-ab__btn--burst {
	overflow: visible;
}

.mws-ew-ab__burst {
	position: absolute;
	top: 50%;
	left: 50%;
	width: 6px;
	height: 6px;
	margin: -3px;
	border-radius: 50%;
	background: var(--mws-ew-ab-fill);
	pointer-events: none;
	z-index: 3;
}

/* ---- Light Sheen ---- */
.mws-ew-ab__btn--sheen {
	overflow: hidden;
}

.mws-ew-ab__sheen {
	position: absolute;
	top: -30%;
	bottom: -30%;
	left: 0;
	width: 72%;
	z-index: 4;
	pointer-events: none;
	background: linear-gradient(
		105deg,
		transparent 0%,
		rgba(255, 255, 255, 0) 18%,
		rgba(255, 255, 255, 0.08) 32%,
		rgba(255, 255, 255, 0.28) 42%,
		rgba(255, 255, 255, 0.55) 48%,
		rgba(255, 255, 255, 0.72) 50%,
		rgba(255, 255, 255, 0.55) 52%,
		rgba(255, 255, 255, 0.28) 58%,
		rgba(255, 255, 255, 0.08) 68%,
		rgba(255, 255, 255, 0) 82%,
		transparent 100%
	);
	opacity: 0;
	will-change: transform, opacity;
	transform: translateZ(0);
}

:is([dir="rtl"], .rtl) .mws-ew-ab__sheen,
.mws-ew-ab:dir(rtl) .mws-ew-ab__sheen {
	left: auto;
	right: 0;
}

/* ---- 3D Tilt ---- */
.mws-ew-ab[data-effect="tilt"] {
	perspective: 900px;
}

.mws-ew-ab__btn--tilt {
	overflow: visible;
	transform-style: preserve-3d;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

@media (hover: hover) and (pointer: fine) {
	.mws-ew-ab__btn--tilt:hover {
		will-change: transform, box-shadow;
	}
}

.mws-ew-ab__btn--tilt .mws-ew-ab__label {
	position: relative;
	transform: translateZ(20px);
	pointer-events: none;
}

/* ---- Curtain Wipe ---- */
.mws-ew-ab__btn--curtain {
	overflow: hidden;
}

.mws-ew-ab__btn--curtain > .mws-ew-ab__label {
	position: relative;
	z-index: 1;
}

.mws-ew-ab__curtain {
	position: absolute;
	top: 0;
	left: 0;
	bottom: 0;
	width: 0;
	z-index: 3;
	overflow: hidden;
	pointer-events: none;
	background: var(--mws-ew-ab-fill);
	color: var(--mws-ew-ab-fill-text);
}

:is([dir="rtl"], .rtl) .mws-ew-ab__curtain,
.mws-ew-ab:dir(rtl) .mws-ew-ab__curtain {
	left: auto;
	right: 0;
}

:is([dir="rtl"], .rtl) .mws-ew-ab__curtain-panel,
.mws-ew-ab:dir(rtl) .mws-ew-ab__curtain-panel {
	position: absolute;
	top: 0;
	right: 0;
}

.mws-ew-ab__curtain-panel {
	display: flex;
	align-items: center;
	justify-content: center;
	height: 100%;
	box-sizing: border-box;
}

.mws-ew-ab__curtain .mws-ew-ab__label,
.mws-ew-ab__curtain .mws-ew-ab__txt,
.mws-ew-ab__curtain .mws-ew-ab__icon {
	color: var(--mws-ew-ab-fill-text);
}

@media (prefers-reduced-motion: reduce) {
	.mws-ew-ab__btn {
		transition: none;
	}

	.mws-ew-ab__glow-bg {
		display: none;
	}

	.mws-ew-ab__btn--glow {
		background: var(--mws-ew-ab-glow-a);
	}

	.mws-ew-ab__sheen {
		display: none;
	}
}
