/* Sigma Winback popup. Colours and radii follow the age gate (.sgate) so the two read as one family.
   Every rule is scoped under #sigma-wb: the theme's own input/button rules outrank a single class. */
/* The script toggles [hidden]; author display rules (e.g. .swb__link) would otherwise override it. */
#sigma-wb[hidden], #sigma-wb [hidden] { display: none !important; }
#sigma-wb {
	position: fixed; inset: 0; z-index: 99985;
	display: flex; align-items: center; justify-content: center; padding: 16px;
	font-family: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
}
#sigma-wb, #sigma-wb * { box-sizing: border-box; white-space: normal; }
html.swb-lock, html.swb-lock body { overflow: hidden; }

#sigma-wb .swb__backdrop {
	position: absolute; inset: 0; background: rgba(7, 8, 10, .72);
	opacity: 0; transition: opacity .2s ease;
}
/* The one elevated surface on the page, so it is the one that carries a shadow. */
#sigma-wb .swb__panel {
	position: relative; width: 100%; max-width: 440px; max-height: calc(100vh - 32px); overflow-y: auto;
	padding: 36px 32px 24px; border-radius: 24px;
	background: #131821; border: 1px solid rgba(221, 182, 77, .22);
	box-shadow: 0 25px 50px -12px rgba(0, 0, 0, .65);
	color: #F5F6F8; text-align: left;
	opacity: 0; transform: translateY(8px); transition: opacity .2s ease, transform .2s ease;
}
#sigma-wb.is-in .swb__backdrop { opacity: 1; }
#sigma-wb.is-in .swb__panel { opacity: 1; transform: none; }

#sigma-wb .swb__x {
	position: absolute; top: 10px; right: 10px; width: 44px; height: 44px; padding: 0;
	display: grid; place-items: center; border: 0; border-radius: 999px;
	background: transparent; color: #8E96A3; font: 400 26px/1 Inter, system-ui, sans-serif; cursor: pointer;
}
#sigma-wb .swb__x:hover { color: #F5F6F8; background: rgba(255, 255, 255, .06); }

#sigma-wb .swb__pill {
	display: inline-block; margin: 0 0 16px; padding: 5px 12px;
	border: 1px solid rgba(221, 182, 77, .40); border-radius: 999px; background: rgba(221, 182, 77, .08);
	color: #DDB64D; font-size: 13px; font-weight: 600; line-height: 1.3;
}
#sigma-wb .swb__title {
	margin: 0 0 10px; padding-right: 28px;
	font-family: Newsreader, Georgia, "Times New Roman", serif; font-size: 30px; font-weight: 500;
	line-height: 1.15; letter-spacing: -.01em; color: #F5F6F8;
}
#sigma-wb .swb__sub { margin: 0 0 22px; font-size: 15px; line-height: 1.6; color: #D7DCE3; }

#sigma-wb .swb__label { display: block; margin: 0 0 6px; font-size: 13px; font-weight: 600; color: #D7DCE3; }
#sigma-wb .swb__input {
	display: block; width: 100%; height: 48px; margin: 0; padding: 0 14px;
	border: 1px solid #66707F; border-radius: 12px; background: #0D1014; box-shadow: none; /* 3.55:1 on the panel */
	color: #F5F6F8; font: 16px/1.2 Inter, system-ui, sans-serif; /* 16px stops iOS zooming in on focus */
}
#sigma-wb .swb__input::placeholder { color: #8E96A3; opacity: 1; }
#sigma-wb .swb__input:hover { border-color: #8E96A3; }

#sigma-wb .swb__btn {
	display: block; width: 100%; height: 50px; margin: 12px 0 0; padding: 0 20px;
	border: 0; border-radius: 999px; background: #DDB64D; color: #07080A;
	font: 700 15px/1 Inter, system-ui, sans-serif; letter-spacing: 0; text-transform: none; cursor: pointer;
	transition: background-color .15s ease;
}
#sigma-wb .swb__btn:hover { background: #E8C65E; color: #07080A; }
#sigma-wb .swb__btn:disabled { opacity: .7; cursor: wait; }

#sigma-wb .swb__msg { min-height: 20px; margin: 10px 0 0; font-size: 13px; line-height: 1.5; color: #F4B7A6; }

#sigma-wb .swb__link {
	display: block; min-height: 44px; margin: 8px auto 0; padding: 10px 14px;
	border: 0; background: transparent; color: #AEB5C0;
	font: 500 14px/1.2 Inter, system-ui, sans-serif; text-decoration: underline; text-underline-offset: 3px; cursor: pointer;
}
#sigma-wb .swb__link:hover { color: #F5F6F8; background: transparent; }
#sigma-wb .swb__fine { margin: 2px 0 0; text-align: center; font-size: 12px; line-height: 1.5; color: #8E96A3; }
#sigma-wb .swb__title--done { margin: 8px 0 4px; padding-right: 28px; outline: none; }

#sigma-wb :focus-visible { outline: 2px solid #DDB64D; outline-offset: 3px; }
/* Focus moves here only so screen readers announce the result; it is not a control, so no ring. */
#sigma-wb .swb__title--done:focus-visible { outline: none; }
#sigma-wb .swb__input:focus-visible { outline-offset: 1px; border-color: #DDB64D; }

/* Bottom sheet once the centred card would crowd the screen edges. */
@media (max-width: 520px) {
	#sigma-wb { align-items: flex-end; padding: 0; }
	#sigma-wb .swb__panel {
		max-width: none; max-height: 92vh; border-radius: 24px 24px 0 0; border-bottom: 0;
		padding: 28px 20px calc(20px + env(safe-area-inset-bottom));
		transform: translateY(24px);
	}
	#sigma-wb .swb__title { font-size: 26px; }
}

@media (prefers-reduced-motion: reduce) {
	#sigma-wb .swb__panel, #sigma-wb .swb__backdrop { transition: none; transform: none; }
}
