/**
 * Modal for ?register=1 on agenda single — aligned with .pvdt-registration-popup
 * and #pvdt-event-registration (event-registration.css tokens).
 */
.pvdt-agenda-register-dialog {
	position: fixed;
	inset: 0;
	width: min(96vw, 640px);
	max-width: none;
	height: fit-content;
	max-height: 90vh;
	margin: auto;
	padding: 0;
	overflow: hidden;
	border: 1px solid var(--bb-rl-border-secondary-color, #e1e3e5);
	border-radius: var(--bb-rl-radius-lg, 12px);
	background: var(--bb-rl-background-color, #fff);
	color: var(--bb-rl-text-color, #3f3f3f);
	box-shadow: 0 16px 48px rgba(0, 0, 0, 0.18);
	box-sizing: border-box;
}

.pvdt-agenda-register-dialog::backdrop {
	background: rgba(12, 12, 13, 0.45);
}

.pvdt-agenda-register-dialog #pvdt-event-registration.registration-form {
	margin: 0;
	max-width: none;
}

.pvdt-agenda-register-dialog .registration-form {
	margin: 0;
	padding: 0 var(--bb-rl-space-300, 24px) var(--bb-rl-space-300, 24px);
	max-height: calc(90vh - 3.25rem);
	overflow: auto;
	box-sizing: border-box;
}

/* AJAX geladen fragment (BuddyBoss directory / groep Agenda): zelfde scrollruimte als .registration-form */
.pvdt-agenda-register-dialog.pvdt-agenda-register-dialog--ajax .pvdt-agenda-registration-fragment {
	margin: 0;
	max-width: none;
}

.pvdt-agenda-register-dialog.pvdt-agenda-register-dialog--ajax .registration-form.pvdt-agenda-registration-fragment .event-registration-form {
	margin: 0;
	max-width: none;
}

.pvdt-agenda-register-dialog__header {
	position: sticky;
	top: 0;
	z-index: 2;
	display: flex;
	align-items: center;
	justify-content: flex-end;
	margin: 0;
	padding: var(--bb-rl-space-100, 8px) var(--bb-rl-space-200, 16px);
	border-bottom: 1px solid var(--bb-rl-border-secondary-color, #e8e8e8);
	border-radius: var(--bb-rl-radius-lg, 12px) var(--bb-rl-radius-lg, 12px) 0 0;
	background: var(--bb-rl-background-color, #fff);
	box-sizing: border-box;
}

.pvdt-agenda-register-dialog__close {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2.5rem;
	height: 2.5rem;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: var(--bb-rl-radius-md, 8px);
	background: transparent;
	font-size: 1.5rem;
	line-height: 1;
	color: var(--bb-rl-text-secondary-color, #3f3f3f);
	cursor: pointer;
	transition: background-color 0.2s ease, color 0.2s ease;
	box-sizing: border-box;
	flex-shrink: 0;
}

.pvdt-agenda-register-dialog__close:hover {
	background: var(--bb-rl-background-tertiary-color, #f0f0f0);
	color: var(--bb-rl-text-color, #1e1e1e);
}

.pvdt-agenda-register-dialog__close:focus {
	outline: none;
}

.pvdt-agenda-register-dialog__close:focus-visible {
	outline: 2px solid var(--bb-rl-background-brand-primary-color, #919141);
	outline-offset: 2px;
}

/* Initial focus lands here after open — avoid chrome default outline strip */
.pvdt-agenda-register-dialog #pvdt-event-registration h2.heading:focus {
	outline: none;
}
