* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

body {
	background-color: #0A1618;
	font-family: 'Inter', sans-serif;
	position: relative;
	min-height: 100vh;
	display: flex;
	justify-content: center;
	align-items: center;
	color: #fff;
	padding: 20px;
	overflow-x: hidden;
}

.card {
	background-color: #0d1f12;
	padding: 24px;
	border-radius: 10px;
	border: 1px solid rgba(255, 255, 255, 0.08);
	width: 100%;
	max-width: 420px;
	max-height: 90vh;
	display: flex;
	flex-direction: column;
	position: relative;
	z-index: 1;
}

.card__container {
	display: flex;
	flex-direction: column;
	gap: 20px;
	flex: 1;
	min-height: 0;
}

.header {
	text-align: center;
}

.header__brand {
	font-size: 1.5rem;
	font-weight: 700;
	color: #fff;
	letter-spacing: -0.02em;
}

.header__subtitle {
	font-size: 0.9rem;
	color: rgba(255, 255, 255, 0.5);
	margin-top: 4px;
}

.amount-search {
	display: flex;
	align-items: center;
	gap: 10px;
	min-height: 56px;
}

.amount-search__slot {
	position: relative;
	flex: 1;
	min-height: 56px;
	min-width: 0;
}

.amount-search__amount,
.amount-search__search {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	border-radius: 10px;
	transition: opacity 0.25s ease, transform 0.25s ease;
}

.amount-search__amount {
	background: rgba(255, 255, 255, 0.06);
	border: 1px solid rgba(255, 255, 255, 0.1);
	padding: 14px 16px;
	gap: 8px;
	cursor: text;
	z-index: 1;
}

.amount-search--open .amount-search__amount {
	opacity: 0;
	pointer-events: none;
	transform: translateY(-8px);
	z-index: 0;
}

.amount-search__search {
	background: rgba(255, 255, 255, 0.06);
	border: 1px solid rgba(255, 255, 255, 0.1);
	padding: 0 16px;
	opacity: 0;
	pointer-events: none;
	transform: translateY(8px);
	z-index: 0;
}

.amount-search--open .amount-search__search {
	opacity: 1;
	pointer-events: auto;
	transform: translateY(0);
	z-index: 1;
}

.amount-search__search-input {
	width: 100%;
	background: transparent;
	border: none;
	color: #fff;
	font-size: 1rem;
	font-family: inherit;
	outline: none;
	padding: 14px 0;
}

.amount-search__search-input::placeholder {
	color: rgba(255, 255, 255, 0.35);
}

.amount-search__toggle {
	flex-shrink: 0;
	width: 44px;
	height: 56px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(255, 255, 255, 0.06);
	border: 1px solid rgba(255, 255, 255, 0.1);
	border-radius: 10px;
	color: rgba(255, 255, 255, 0.7);
	cursor: pointer;
	transition: background 0.2s, color 0.2s;
}

.amount-search__toggle:hover {
	background: rgba(255, 255, 255, 0.1);
	color: #fff;
}

.amount-search__toggle-icon {
	width: 20px;
	height: 20px;
}

.amount-search--open .amount-search__toggle {
	background: rgba(255, 255, 255, 0.1);
	color: #fff;
}

.amount-search__input {
	flex: 1;
	min-width: 0;
	background: transparent;
	border: none;
	color: #fff;
	font-size: 1.75rem;
	font-weight: 600;
	font-family: inherit;
	text-align: center;
	outline: none;
	height: 100%;
}

.amount-search__input::placeholder {
	color: rgba(255, 255, 255, 0.35);
}

.amount-search__currency {
	font-size: 1.5rem;
	font-weight: 600;
	color: rgba(255, 255, 255, 0.85);
	flex-shrink: 0;
}

.payment-methods {
	display: flex;
	flex-direction: column;
	gap: 10px;
	flex: 1;
	min-height: 0;
}

.payment-methods__scroll {
	overflow-y: hidden;
	overflow-x: hidden;
	border-radius: 10px;
	max-height: 164px;
	transition: max-height 0.25s ease;
}

.payment-methods__scroll--expanded {
	max-height: 280px;
	overflow-y: auto;
	padding-right: 4px;
}

.payment-methods__scroll::-webkit-scrollbar {
	width: 6px;
}

.payment-methods__scroll::-webkit-scrollbar-track {
	background: rgba(255, 255, 255, 0.05);
	border-radius: 3px;
}

.payment-methods__scroll::-webkit-scrollbar-thumb {
	background: rgba(255, 255, 255, 0.2);
	border-radius: 3px;
}

.payment-methods__grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 10px;
}

.payment-option {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 6px;
	background: rgba(255, 255, 255, 0.05);
	border: 1px solid rgba(255, 255, 255, 0.08);
	border-radius: 10px;
	padding: 14px 8px;
	color: #fff;
	font-size: 0.75rem;
	font-family: inherit;
	cursor: pointer;
	transition: background 0.2s, border-color 0.2s;
	aspect-ratio: 1;
	min-height: 72px;
}

.payment-option:hover {
	background: rgba(255, 255, 255, 0.09);
	border-color: rgba(255, 255, 255, 0.12);
}

.payment-option--hidden {
	display: none;
}

.payment-option--selected {
	border-color: #1a9669;
	background: rgba(26, 150, 105, 0.12);
}

.payment-option__icon,
.payment-option__fallback {
	flex-shrink: 0;
}

.payment-option__icon {
	width: 28px;
	height: 28px;
	object-fit: contain;
}

.payment-option__fallback {
	font-size: 1.1rem;
	font-weight: 700;
	color: rgba(255, 255, 255, 0.6);
}

.payment-methods__show-more {
	width: 100%;
	font-size: 0.85rem;
	color: rgba(255, 255, 255, 0.6);
	background: transparent;
	border: none;
	cursor: pointer;
	font-family: inherit;
	padding: 8px 0;
	text-align: center;
	transition: color 0.2s;
}

.payment-methods__show-more:hover {
	color: rgba(255, 255, 255, 0.85);
}

.payment-methods__show-more[aria-expanded="true"] {
	display: none;
}

.pay-btn {
	width: 100%;
	background: #1a9669;
	color: #fff;
	border: none;
	border-radius: 10px;
	padding: 14px 20px;
	font-size: 1rem;
	font-weight: 600;
	font-family: inherit;
	cursor: pointer;
	transition: background 0.2s, transform 0.1s;
	margin-top: auto;
}

.pay-btn:hover {
	background: #22b87a;
}

.pay-btn:active {
	transform: scale(0.98);
}

.ruby {
	position: absolute;
	width: min(300px, 40vw);
	height: auto;
	opacity: 0.5;
	pointer-events: none;
}

.ruby--bottom-left {
	bottom: 0;
	left: 0;
	animation: ruby-float-1 6s ease-in-out infinite;
}

.ruby--top-right {
	top: 0;
	right: 0;
	animation: ruby-float-2 7s ease-in-out infinite;
}

@keyframes ruby-float-1 {
	0%, 100% {
		transform: translate(0, 0) rotate(0deg);
	}
	33% {
		transform: translate(8px, -6px) rotate(1deg);
	}
	66% {
		transform: translate(-5px, 4px) rotate(-1deg);
	}
}

@keyframes ruby-float-2 {
	0%, 100% {
		transform: translate(0, 0) rotate(0deg);
	}
	33% {
		transform: translate(-6px, 8px) rotate(-1deg);
	}
	66% {
		transform: translate(4px, -5px) rotate(1deg);
	}
}

@media (max-width: 380px) {
	.card {
		padding: 16px;
	}

	.header__brand {
		font-size: 1.35rem;
	}

	.amount-search__input {
		font-size: 1.5rem;
	}

	.amount-search__currency {
		font-size: 1.35rem;
	}

	.payment-methods__scroll {
		max-height: 152px;
	}

	.payment-methods__scroll--expanded {
		max-height: 260px;
	}

	.payment-option {
		padding: 10px 6px;
		font-size: 0.7rem;
		min-height: 64px;
	}

	.payment-option__icon {
		width: 24px;
		height: 24px;
	}
}

@media (min-width: 500px) {
	.ruby {
		width: 280px;
	}
}
