 
.h2g-popup {
	pointer-events: none;
}

 

 
.h2g-popup__card {
	position: relative;
	background: var(--wp--preset--color--white);
	border-radius: var( --radius-lg, 16px );
	box-shadow: var( --shadow-lg, 0 20px 60px color-mix(in srgb, var(--wp--preset--color--base) 18%, transparent) );
	overflow: hidden;
}

 
.h2g-popup__close {
	position: absolute;
	top: 0.75rem;
	right: 0.75rem;
	z-index: 10;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 2rem;
	height: 2rem;
	border: none;
	border-radius: 50%;
	background: color-mix(in srgb, var(--wp--preset--color--base) 6%, transparent);
	color: var(--wp--preset--color--muted);
	cursor: pointer;
	transition: background 0.2s, color 0.2s;
	padding: 0;
	line-height: 1;
	 
	font-size: 1.3rem;
}
.h2g-popup__close:hover {
	background: color-mix(in srgb, var(--wp--preset--color--base) 14%, transparent);
	color: var(--wp--preset--color--base);
}

 
.h2g-popup__img-wrap {
	margin: 0;
	line-height: 0;
}
.h2g-popup__img {
	width: 100%;
	max-height: 240px;
	object-fit: cover;
	display: block;
}

 
.h2g-popup__body {
	padding: 1.75rem 1.75rem 1.75rem;
}
.h2g-popup__heading {
	font-family: var( --font-display, 'Sofia Pro', sans-serif );
	font-size: 1.35rem;
	font-weight: 700;
	color: var(--wp--preset--color--base);
	margin: 0 0 0.65rem;
	padding-right: 1.5rem;  
	line-height: 1.25;
}
.h2g-popup__text {
	font-size: 0.95rem;
	color: var(--wp--preset--color--text);
	line-height: 1.65;
	margin: 0 0 1.25rem;
}

 
.h2g-popup__text p {
	margin: 0 0 0.75rem;
}
.h2g-popup__text > *:last-child {
	margin-bottom: 0;
}
.h2g-popup__text strong,
.h2g-popup__text b {
	font-weight: 700;
	color: var(--wp--preset--color--base);
}
.h2g-popup__text a {
	color: var(--wp--preset--color--primary);
	text-decoration: underline;
}
.h2g-popup__text a:hover {
	color: var(--wp--preset--color--accent);
}
.h2g-popup__text ul,
.h2g-popup__text ol {
	margin: 0 0 0.75rem;
	padding-left: 1.25rem;
}
.h2g-popup__text ul {
	list-style: disc;
}
.h2g-popup__text ol {
	list-style: decimal;
}
.h2g-popup__text li {
	margin-bottom: 0.3rem;
}
.h2g-popup__btn {
	display: inline-flex;
}

 
.h2g-popup--narrow .h2g-popup__card  { max-width: 360px; }
.h2g-popup--medium .h2g-popup__card  { max-width: 480px; }
.h2g-popup--wide   .h2g-popup__card  { max-width: 600px; }

 
.h2g-popup--modal {
	position: fixed;
	inset: 0;
	z-index: 9999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 1.25rem;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.75s var( --ease, cubic-bezier( 0.4, 0, 0.2, 1 ) ),
	            visibility 0.75s var( --ease, cubic-bezier( 0.4, 0, 0.2, 1 ) );
}
.h2g-popup--modal.is-visible {
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
}

 
.h2g-popup__overlay {
	position: absolute;
	inset: 0;
	background: color-mix(in srgb, var(--wp--preset--color--base) 52%, transparent);
	cursor: pointer;
}

 
.h2g-popup--modal .h2g-popup__card {
	position: relative;
	z-index: 1;
	width: 100%;
	max-height: 100%;
	overflow-y: auto;
	overscroll-behavior: contain;
	transform: scale( 0.94 ) translateY( 10px );
	transition: transform 0.9s var( --ease, cubic-bezier( 0.4, 0, 0.2, 1 ) );
}
.h2g-popup--modal.is-visible .h2g-popup__card {
	transform: scale( 1 ) translateY( 0 );
}

 
.h2g-popup--modal .h2g-popup__close {
	position: sticky;
	top: 0.75rem;
	margin: 0.75rem 0.75rem -2.75rem auto;
}

 
@media ( min-width: 601px ) {
	.admin-bar .h2g-popup--modal {
		top: var( --wp-admin--admin-bar--height, 32px );
	}
}

 
.h2g-popup--modal .gform_wrapper .gfield textarea.medium,
.h2g-popup--modal .gform_wrapper .gfield textarea.large {
	min-height: 130px;
	height: 130px;
}

 
 
.h2g-popup--slide-in {
	position: fixed;
	z-index: 9999;
	visibility: hidden;
}
.h2g-popup--slide-in.is-visible {
	visibility: visible;
}

 
.h2g-popup--bottom-right { bottom: 1.5rem; right: 1.5rem; }
.h2g-popup--bottom-left  { bottom: 1.5rem; left: 1.5rem;  }
.h2g-popup--top-right    { top: calc( 1.5rem + 7rem ); right: 1.5rem; }
.h2g-popup--top-left     { top: calc( 1.5rem + 7rem ); left: 1.5rem;  }

 
.h2g-popup--slide-in .h2g-popup__card {
	width: 100%;
	opacity: 0;
	pointer-events: none;
	transition: transform 0.9s var( --ease, cubic-bezier( 0.4, 0, 0.2, 1 ) ),
	            opacity   0.9s var( --ease, cubic-bezier( 0.4, 0, 0.2, 1 ) );
}

 
.h2g-popup--bottom-right .h2g-popup__card,
.h2g-popup--bottom-left  .h2g-popup__card {
	transform: translateY( calc( 100% + 2rem ) );
}
 
.h2g-popup--top-right .h2g-popup__card,
.h2g-popup--top-left  .h2g-popup__card {
	transform: translateY( calc( -100% - 2rem ) );
}

 
.h2g-popup--slide-in.is-visible .h2g-popup__card {
	transform: translateY( 0 );
	opacity: 1;
	pointer-events: auto;
}
.h2g-popup--slide-in.is-visible {
	pointer-events: auto;
}

 
.h2g-popup--slide-in .h2g-popup__card::before {
	content: "";
	display: block;
	height: 4px;
	background: var(--wp--preset--color--primary);
}

 
@media ( max-width: 600px ) {
	 
	.h2g-popup--modal {
		padding: 1.5rem 1.25rem;
		align-items: center;
	}
	.h2g-popup--modal .h2g-popup__card {
		max-width: 100% !important;
	}
	.h2g-popup--slide-in {
		left: 0.75rem !important;
		right: 0.75rem !important;
		bottom: 0.75rem !important;
		top: auto !important;
	}
	.h2g-popup--narrow .h2g-popup__card,
	.h2g-popup--medium .h2g-popup__card,
	.h2g-popup--wide   .h2g-popup__card {
		max-width: 100%;
	}
	.h2g-popup--top-right .h2g-popup__card,
	.h2g-popup--top-left  .h2g-popup__card {
		transform: translateY( calc( 100% + 2rem ) );
	}

	 
	.h2g-popup__img {
		max-height: 140px;
	}
	.h2g-popup__body {
		padding: 1.25rem 1.25rem 1.4rem;
	}
	.h2g-popup__heading {
		font-size: 1.1rem;
	}
	.h2g-popup__text {
		font-size: 0.875rem;
		line-height: 1.55;
	}
}

 
@media ( prefers-reduced-motion: reduce ) {
	.h2g-popup--modal,
	.h2g-popup--modal .h2g-popup__card,
	.h2g-popup--slide-in .h2g-popup__card {
		transition: opacity 0.15s ease, visibility 0.15s ease;
		transform: none !important;
	}
}
