/* =========================================================================
   PeptiNova — Age Gate plugin skin (Age Gate by Phil Baker, v3.x).

   DESIGN ONLY. The gate's content, logic and settings stay 100% in the
   plugin; this restyles its frontend markup into the storefront's age gate
   (src/components/age-gate.tsx):

     overlay  fixed inset-0 z-100 bg-navy/70 backdrop-blur(8px) p-4
     card     max-w-md (448px) rounded-3xl bg-white p-6 sm:p-8 shadow-2xl
     logo     h-9 (36px) centered
     h2       mt-6 text-xl sm:text-2xl bold navy
     p        mt-3 text-sm sm:text-base muted
     buttons  mt-6 stacked (gap 12px) / side by side ≥640, each flex-1,
              pill px-6 py-3 text-sm semibold — "I Agree" solid primary,
              "I Do Not Agree" white with border
     remember mt-5 text-sm muted, 16px checkbox accent primary
     fine print mt-5 text-xs leading-relaxed muted

   Plugin markup (v3): .age-gate__wrapper > .age-gate__background-color +
   .age-gate__background + .age-gate[role=dialog] > form.age-gate__form >
   .age-gate__heading(img) + h2.age-gate__headline + p.age-gate__subheadline
   + .age-gate__fields(p.age-gate__challenge + .age-gate__buttons) +
   .age-gate__remember-wrapper + .age-gate__errors +
   .age-gate__additional-information.
   ========================================================================= */

/* Overlay: dim + blur the page (the plugin's own opaque white layer is
   turned into the navy/70 glass) */
.age-gate__wrapper {
	--ag-form-background: #ffffff;
	--ag-form-radius: 1.5rem;
	--ag-form-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
	--ag-form-max-width: 28rem;
	--ag-form-padding: 1.5rem;
	--ag-wrapper-padding: 1rem;
	--ag-text-align: center;
	--ag-button-radius: 9999px;
	--ag-button-gap: 0.75rem;
	--ag-button-padding: 0.75rem 1.5rem;
	--ag-button-size: 0.875rem;
	--ag-button-weight: 600;
	--ag-text-headline-size: 1.25rem;
	--ag-text-headline-weight: 700;
	--ag-text-headline-margin: 1.5rem 0 0;
	--ag-text-subheadline-size: 0.875rem;
	--ag-text-subheadline-weight: 400;
	--ag-text-subheadline-margin: 0.75rem 0 0;
	--ag-text-additional-size: 0.75rem;
	--ag-text-additional-margin: 1.25rem 0 0;
	--ag-remember-margin: 1.25rem 0 0;
	--ag-remember-size: 0.875rem;
	--ag-remember-spacing: 0.5rem;
	--ag-fields-margin: 1.5rem auto 0;
	--ag-logo-height: 2.25rem;
	position: fixed !important;
	inset: 0;
	z-index: 999999;
	display: flex !important;
	align-items: center;
	justify-content: center;
	padding: 1rem !important;
	font-family: var(--font-display, 'Jost', system-ui, sans-serif);
	box-sizing: border-box;
}

.age-gate__wrapper *,
.age-gate__wrapper *::before,
.age-gate__wrapper *::after {
	box-sizing: border-box;
}

.age-gate__background-color,
.age-gate__background {
	position: fixed !important;
	inset: 0;
	height: 100% !important;
	width: 100% !important;
}

.age-gate__background-color {
	background: rgba(18, 13, 59, 0.7) !important;
	opacity: 1 !important;
	-webkit-backdrop-filter: blur(8px) !important;
	backdrop-filter: blur(8px) !important;
	z-index: 0 !important;
}

.age-gate__background {
	background: transparent !important;
	opacity: 1 !important;
	z-index: 1 !important;
}

/* The dialog card */
.age-gate__wrapper .age-gate {
	position: relative;
	z-index: 10 !important;
	width: 100%;
	max-width: 28rem !important;
	max-height: calc(100vh - 2rem);
	overflow-y: auto;
	margin: auto;
	background: #ffffff !important;
	border: 0 !important;
	border-radius: 1.5rem !important;
	box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25) !important;
	padding: 1.5rem !important;
	text-align: center;
	color: var(--color-text, #0a0a0a);
	font-family: inherit;
}

@media (min-width: 640px) {
	.age-gate__wrapper .age-gate {
		padding: 2rem !important;
	}
}

.age-gate__wrapper .age-gate__form {
	display: block;
	height: auto;
	margin: 0;
}

/* Logo */
.age-gate__wrapper .age-gate__heading {
	margin: 0;
}

.age-gate__wrapper .age-gate__heading-title--logo,
.age-gate__wrapper .age-gate__heading img {
	display: block;
	margin: 0 auto;
	height: 2.25rem !important;
	width: auto !important;
	max-width: 100%;
}

/* Headline + sub headline */
.age-gate__wrapper .age-gate__headline {
	margin: 1.5rem 0 0 !important;
	font-family: inherit;
	font-size: 1.25rem !important;
	line-height: 1.75rem;
	font-weight: 700 !important;
	color: var(--color-navy, #120d3b);
}

.age-gate__wrapper .age-gate__subheadline {
	margin: 0.75rem 0 0 !important;
	font-family: inherit;
	font-size: 0.875rem !important;
	line-height: 1.25rem;
	font-weight: 400 !important;
	color: var(--color-text-muted, #6b6b70);
}

@media (min-width: 640px) {
	.age-gate__wrapper .age-gate__headline {
		font-size: 1.5rem !important;
		line-height: 2rem;
	}

	.age-gate__wrapper .age-gate__subheadline {
		font-size: 1rem !important;
		line-height: 1.5rem;
	}
}

/* The plugin's extra "Do you confirm…?" question line is not part of the
   storefront design (its wording lives in Age Gate → Messages) */
.age-gate__wrapper .age-gate__challenge {
	display: none;
}

/* Buttons */
.age-gate__wrapper .age-gate__fields {
	margin: 1.5rem auto 0 !important;
	max-width: 100%;
	padding: 0;
}

.age-gate__wrapper .age-gate__buttons {
	display: flex;
	flex-direction: column;
	align-items: stretch;
	gap: 0.75rem !important;
}

@media (min-width: 640px) {
	.age-gate__wrapper .age-gate__buttons {
		flex-direction: row;
	}
}

.age-gate__wrapper .age-gate__submit,
.age-gate__wrapper button.age-gate__submit--yes,
.age-gate__wrapper button.age-gate__submit--no {
	appearance: none;
	-webkit-appearance: none;
	flex: 1 1 0%;
	display: inline-block;
	width: auto;
	margin: 0 !important;
	border-radius: 9999px !important;
	padding: 0.75rem 1.5rem !important;
	font-family: inherit;
	font-size: 0.875rem !important;
	line-height: 1.25rem;
	font-weight: 600 !important;
	text-transform: capitalize; /* "I agree" → "I Agree" (design only) */
	cursor: pointer;
	text-decoration: none;
	transition: none;
}

.age-gate__wrapper button.age-gate__submit--yes {
	background: var(--color-primary, #2571a6) !important;
	border: 1px solid var(--color-primary, #2571a6) !important;
	color: #ffffff !important;
}

.age-gate__wrapper button.age-gate__submit--yes:hover,
.age-gate__wrapper button.age-gate__submit--yes:focus-visible {
	background: var(--color-primary-dark, #1c5c87) !important;
	border-color: var(--color-primary-dark, #1c5c87) !important;
}

.age-gate__wrapper button.age-gate__submit--no {
	background: #ffffff !important;
	border: 1px solid var(--color-border, #e4e4e7) !important;
	color: var(--color-navy, #120d3b) !important;
}

.age-gate__wrapper button.age-gate__submit--no:hover,
.age-gate__wrapper button.age-gate__submit--no:focus-visible {
	border-color: var(--color-text-muted, #6b6b70) !important;
}

/* Remember me */
.age-gate__wrapper .age-gate__remember-wrapper {
	margin: 1.25rem 0 0 !important;
}

.age-gate__wrapper .age-gate__remember {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
	margin: 0;
	font-size: 0.875rem;
	font-weight: 400;
	color: var(--color-text-muted, #6b6b70);
	cursor: pointer;
}

.age-gate__wrapper .age-gate__remember-field {
	width: 1rem;
	height: 1rem;
	margin: 0;
	border-radius: 0.25rem;
	accent-color: var(--color-primary, #2571a6);
}

.age-gate__wrapper .age-gate__remember-text {
	margin: 0;
	font-size: 0.875rem;
	font-weight: 400;
}

/* Errors */
.age-gate__wrapper .age-gate__errors {
	padding: 0;
}

.age-gate__wrapper .age-gate__errors:not(:empty) {
	margin-top: 0.75rem;
	font-size: 0.8125rem;
	font-weight: 500;
	color: var(--pn-red, #e7000b);
}

.age-gate__wrapper .age-gate__error {
	color: var(--pn-red, #e7000b);
	font-weight: 500;
}

/* Fine print / additional information */
.age-gate__wrapper .age-gate__additional-information {
	margin: 1.25rem 0 0 !important;
	padding: 0;
	font-size: 0.75rem !important;
	line-height: 1.625;
	color: var(--color-text-muted, #6b6b70);
}

.age-gate__wrapper .age-gate__additional-information p {
	margin: 0;
	font-size: inherit;
	line-height: inherit;
	color: inherit;
}

.age-gate__wrapper .age-gate__additional-information p + p {
	margin-top: 0.5rem;
}

/* Loader overlay (shown while the plugin processes the choice) */
.age-gate__wrapper .age-gate__loader {
	background: rgba(18, 13, 59, 0.7);
	color: #ffffff;
}

/* Keep the page from scrolling behind the open gate */
body.age-gate-visible,
body.age-restriction--visible,
html.age-gate__restricted body {
	overflow: hidden;
}

/* The plugin removes the gate on the wrapper's own transitionend; a
   transition on any descendant would bubble and trigger that removal
   twice, so descendants never animate. */
.age-gate__wrapper .age-gate,
.age-gate__wrapper .age-gate * {
	transition: none !important;
}