.mobile-payment-history-open {
	overflow: hidden;
}

.mobile-payment-history[hidden] {
	display: none !important;
}

.mobile-payment-history {
	position: fixed;
	inset: 0;
	z-index: 1220;
	background: #f6fbf7;
	color: #17211b;
	display: flex;
	flex-direction: column;
}

.mobile-payment-history__header {
	position: sticky;
	top: 0;
	z-index: 2;
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 14px 16px;
	background: rgba(246, 251, 247, 0.96);
	border-bottom: 1px solid rgba(35, 102, 65, 0.12);
	backdrop-filter: blur(12px);
}

.mobile-payment-history__back,
.mobile-payment-history-secondary,
.mobile-payment-history-link {
	border: 1px solid rgba(35, 102, 65, 0.16);
	background: #ffffff;
	color: #216143;
	border-radius: 999px;
	font-weight: 800;
	cursor: pointer;
}

.mobile-payment-history__back,
.mobile-payment-history-secondary {
	padding: 10px 14px;
}

.mobile-payment-history-link {
	width: 100%;
	min-height: 42px;
	padding: 9px 12px;
}

.mobile-payment-history__title {
	min-width: 0;
	display: grid;
	gap: 2px;
}

.mobile-payment-history__title span,
.mobile-payment-history__title small,
.mobile-payment-history-summary span,
.mobile-payment-history-fields span,
.mobile-payment-history-detail span {
	color: #5f7468;
	font-size: 0.72rem;
	font-weight: 800;
	letter-spacing: 0.06em;
	text-transform: uppercase;
}

.mobile-payment-history__title strong {
	font-size: 1.1rem;
	line-height: 1.2;
	overflow-wrap: anywhere;
}

.mobile-payment-history__body {
	flex: 1;
	overflow: auto;
	display: grid;
	align-content: start;
	gap: 12px;
	padding: 14px 14px calc(92px + env(safe-area-inset-bottom));
	-webkit-overflow-scrolling: touch;
}

.mobile-payment-history-summary,
.mobile-payment-history-card,
.mobile-payment-history-detail,
.mobile-payment-history-receipt-viewer {
	background: #ffffff;
	border: 1px solid rgba(35, 102, 65, 0.12);
	border-radius: 18px;
	box-shadow: 0 14px 30px rgba(15, 23, 42, 0.08);
}

.mobile-payment-history-summary {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
	overflow: hidden;
	gap: 1px;
}

.mobile-payment-history-summary div {
	display: grid;
	gap: 4px;
	padding: 12px;
	background: linear-gradient(180deg, #ffffff, #f8fcf9);
}

.mobile-payment-history-summary strong,
.mobile-payment-history-fields strong,
.mobile-payment-history-detail strong {
	font-size: 1rem;
	color: #122017;
	overflow-wrap: anywhere;
}

.mobile-payment-history-list {
	display: grid;
	gap: 12px;
}

.mobile-payment-history-card {
	display: grid;
	gap: 12px;
	padding: 14px;
}

.mobile-payment-history-card__top {
	display: flex;
	justify-content: space-between;
	gap: 12px;
	align-items: flex-start;
}

.mobile-payment-history-card__top div {
	display: grid;
	gap: 3px;
}

.mobile-payment-history-card__top strong:last-child {
	color: #145c37;
	font-size: 1.05rem;
	white-space: nowrap;
}

.mobile-payment-history-fields,
.mobile-payment-history-detail {
	display: grid;
	gap: 1px;
	overflow: hidden;
}

.mobile-payment-history-fields div,
.mobile-payment-history-detail div {
	display: grid;
	gap: 4px;
	padding: 10px 0;
	border-bottom: 1px solid rgba(35, 102, 65, 0.1);
}

.mobile-payment-history-detail {
	padding: 4px 14px;
}

.mobile-payment-history-fields div:last-child,
.mobile-payment-history-detail div:last-child {
	border-bottom: 0;
}

.mobile-payment-history__state,
.mobile-payment-history-note,
.mobile-payment-history-fallback {
	margin: 0;
	padding: 12px;
	border-radius: 14px;
	background: #eaf7ef;
	color: #216143;
	font-weight: 800;
	line-height: 1.35;
}

.mobile-payment-history__state.is-error {
	background: #fff1f2;
	border: 1px solid #fecdd3;
	color: #9f1239;
}

.mobile-payment-history-actions {
	display: grid;
	gap: 10px;
}

.mobile-payment-history-share-feedback {
	display: grid;
	gap: 4px;
	padding: 12px 14px;
	border: 1px solid rgba(35, 102, 65, 0.14);
	border-radius: 16px;
	background: #eef9f1;
	color: #17211b;
}

.mobile-payment-history-share-feedback.is-error {
	background: #fff1f2;
	border-color: #fecdd3;
}

.mobile-payment-history-share-feedback strong {
	color: #145c37;
	font-size: 0.9rem;
}

.mobile-payment-history-share-feedback.is-error strong {
	color: #9f1239;
}

.mobile-payment-history-share-feedback span {
	color: #5f7468;
	font-size: 0.82rem;
	font-weight: 800;
	overflow-wrap: anywhere;
}

.mobile-payment-history-actions .mobile-action-button,
.mobile-payment-history-actions .mobile-payment-history-secondary {
	width: 100%;
	justify-content: center;
	min-height: 48px;
}

.mobile-payment-history-receipt-viewer {
	min-height: min(72vh, 740px);
	overflow: hidden;
}

.mobile-payment-history-receipt-viewer iframe {
	display: block;
	width: 100%;
	height: min(72vh, 740px);
	border: 0;
	background: #ffffff;
}

.mobile-payment-history-fallback {
	font-size: 0.86rem;
}

.mobile-payment-history-fallback p {
	margin: 0;
}

.mobile-payment-history__back:focus-visible,
.mobile-payment-history-secondary:focus-visible,
.mobile-payment-history-link:focus-visible {
	outline: 3px solid rgba(34, 197, 94, 0.28);
	outline-offset: 2px;
}

@media (min-width: 760px) {
	.mobile-payment-history {
		inset: 24px max(24px, calc((100vw - 760px) / 2));
		border-radius: 24px;
		min-height: 0;
		box-shadow: 0 24px 60px rgba(15, 23, 42, 0.22);
		overflow: hidden;
	}

	.mobile-payment-history__body {
		padding-bottom: 24px;
	}
}
