/* WordPress 7+ no longer supplies the legacy has-2-columns front-end layout. */
article h2[id],
article h3[id] {
	scroll-margin-top: 90px;
}

.wp-block-pay-box > .wp-block-columns.has-2-columns {
	display: flex;
	flex-wrap: nowrap !important;
	align-items: flex-start;
	gap: 20px;
	margin: 0;
}

.wp-block-pay-box > .wp-block-columns.has-2-columns > .wp-block-column {
	flex: 1 1 0;
	min-width: 0;
	margin: 0;
}

.wp-block-pay-box .gallery.carousel,
.wp-block-pay-box .gallery.carousel .carousel-inner,
.wp-block-pay-box .gallery.carousel .item {
	width: 100%;
}

@media (max-width: 781px) {
	.wp-block-pay-box > .wp-block-columns.has-2-columns {
		display: block;
	}

	.wp-block-pay-box > .wp-block-columns.has-2-columns > .wp-block-column + .wp-block-column {
		margin-top: 20px;
	}
}

/*
 * PANDA title blocks already use the theme's article title decoration on the
 * front end. The legacy block-editor stylesheet also creates a ::before bar;
 * if that stylesheet is cached or loaded globally, both bars are rendered.
 */
article .wp-block-pandastudio-title > .title_style_01::before {
	content: none !important;
	display: none !important;
}

article .wp-block-pandastudio-title > .title_style_01 > h3 {
	margin: 0 !important;
	font-size: 20px !important;
	font-weight: 400 !important;
	line-height: 1.6 !important;
	color: inherit !important;
}

/* Keep the resource password in the same three-column action row as download. */
.wp-block-pay-box .pay--box > .pay-box-password-item {
	width: auto;
	max-width: calc((100% - 10px) * 2 / 3);
}

.wp-block-pay-box .pay-box-password-item .pay-box-pwd {
	position: static;
}

.wp-block-pay-box .pay-box-password-item .pay-box-pwd .pwd {
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 37px;
	margin-top: 0;
	line-height: 25px;
	white-space: nowrap;
}

@media (max-width: 600px) {
	.wp-block-pay-box .pay--box > .pay-box-password-item {
		width: 100%;
		max-width: 100%;
		margin-top: 10px;
		margin-right: 0;
	}
}

/* Sidebar user cards remain interactive even when the optional Chat UI is off. */
.nirvana-user-card-trigger {
	cursor: pointer;
}

.nirvana-user-card-trigger:focus-visible {
	outline: 2px solid #20a0ff;
	outline-offset: 3px;
}

body.nirvana-user-card-open {
	overflow: hidden;
}

.nirvana-user-card-fallback {
	position: fixed;
	z-index: 2147483000;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
	background: rgba(15, 23, 42, 0.45);
	backdrop-filter: blur(3px);
}

.nirvana-user-card-fallback__card {
	position: relative;
	isolation: isolate;
	overflow: hidden;
	width: min(320px, 100%);
	padding: 30px 24px 24px;
	border: 1px solid rgba(32, 160, 255, 0.22);
	border-radius: 12px;
	background: linear-gradient(145deg, #edf7ff 0%, #fff 52%, #f2f6fc 100%);
	box-shadow:
		0 22px 55px rgba(31, 45, 61, 0.3),
		inset 0 1px 0 rgba(255, 255, 255, 0.9);
	text-align: center;
}

.nirvana-user-card-fallback__card::before,
.nirvana-user-card-fallback__card::after {
	position: absolute;
	z-index: -1;
	border-radius: 50%;
	content: '';
	pointer-events: none;
}

.nirvana-user-card-fallback__card::before {
	top: -90px;
	left: -70px;
	width: 230px;
	height: 230px;
	background: radial-gradient(circle, rgba(32, 160, 255, 0.24), rgba(32, 160, 255, 0) 70%);
}

.nirvana-user-card-fallback__card::after {
	right: -90px;
	bottom: -120px;
	width: 260px;
	height: 260px;
	background: radial-gradient(circle, rgba(142, 206, 68, 0.15), rgba(142, 206, 68, 0) 70%);
}

.nirvana-user-card-fallback__close {
	position: absolute;
	top: 8px;
	right: 10px;
	width: 32px;
	height: 32px;
	padding: 0;
	border: 0;
	background: transparent;
	color: #8492a6;
	font: 24px/32px Arial, sans-serif;
	cursor: pointer;
}

.nirvana-user-card-fallback__avatar {
	display: flex;
	justify-content: center;
	margin-bottom: 14px;
}

.nirvana-user-card-fallback__avatar .avatar--box-mini {
	position: relative;
	width: 72px;
	height: 72px;
}

.nirvana-user-card-fallback__avatar img.avatar {
	display: block;
	width: 72px;
	height: 72px;
	border-radius: 12px;
	object-fit: cover;
	box-shadow: 0 8px 18px rgba(31, 45, 61, 0.2);
}

.nirvana-user-card-fallback__name {
	color: #34495e;
	font-size: 18px;
	font-weight: 600;
	line-height: 1.5;
}

.nirvana-user-card-fallback__detail {
	margin-top: 8px;
	padding: 9px 12px;
	border: 1px solid rgba(132, 146, 166, 0.12);
	border-radius: 6px;
	background: rgba(255, 255, 255, 0.72);
	box-shadow: 0 6px 18px rgba(31, 45, 61, 0.06);
	color: #8492a6;
	font-size: 14px;
	line-height: 1.6;
	word-break: break-word;
}

/* Keep the sidebar follow action on one line with Font Awesome 7. */
.widget-userstop li .pm-sidebar-follow-btn,
.pm-sidebar-follow-btn {
	display: inline-flex !important;
	align-items: center;
	justify-content: center;
	gap: 4px;
	box-sizing: border-box;
	width: auto !important;
	min-width: 58px;
	height: 26px;
	padding: 0 10px !important;
	font-size: 12px !important;
	line-height: 1 !important;
	white-space: nowrap !important;
}

.widget-userstop li .pm-sidebar-follow-btn > i,
.pm-sidebar-follow-btn > i {
	flex: 0 0 auto;
	margin: 0;
	font-size: 13px !important;
	line-height: 1 !important;
}
