#wpsg-tool {
	--wpsg-navy: #17395f;
	--wpsg-navy-deep: #0d2744;
	--wpsg-blue-soft: #edf4fb;
	--wpsg-yellow: #ffe852;
	--wpsg-cream: #fffdf5;
	--wpsg-line: #dce5ef;
	--wpsg-text: #1b2a3a;
	--wpsg-muted: #667587;
	color: var(--wpsg-text);
	font-size: 16px;
	line-height: 1.65;
}

#wpsg-tool *,
#wpsg-tool *::before,
#wpsg-tool *::after {
	box-sizing: border-box;
}

#wpsg-tool .wpsg__intro {
	max-width: 760px;
	margin: 0 auto 25px;
	text-align: center;
}

#wpsg-tool .wpsg__eyebrow,
#wpsg-tool .wpsg__success {
	display: inline-flex;
	align-items: center;
	padding: 6px 12px;
	border-radius: 999px;
	background: var(--wpsg-yellow);
	color: #1c2c3d;
	font-size: 13px;
	font-weight: 800;
	letter-spacing: .02em;
}

#wpsg-tool .wpsg__intro h2 {
	margin: 13px 0 8px;
	color: var(--wpsg-navy-deep);
	font-size: clamp(28px, 4vw, 42px);
	line-height: 1.2;
}

#wpsg-tool .wpsg__intro p {
	margin: 0;
	color: var(--wpsg-muted);
}

#wpsg-tool .wpsg__steps {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 10px;
	max-width: 650px;
	margin: 0 auto 22px;
	padding: 0;
	list-style: none;
}

#wpsg-tool .wpsg__steps li {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	color: var(--wpsg-navy);
	font-size: 14px;
	font-weight: 750;
}

#wpsg-tool .wpsg__steps span {
	display: inline-grid;
	place-items: center;
	width: 28px;
	height: 28px;
	border-radius: 50%;
	background: var(--wpsg-navy);
	color: #fff;
	font-size: 13px;
}

#wpsg-tool .wpsg__form,
#wpsg-tool .wpsg__result {
	max-width: 940px;
	margin: 0 auto;
	padding: clamp(20px, 4vw, 38px);
	border: 1px solid var(--wpsg-line);
	border-radius: 24px;
	background: #fff;
	box-shadow: 0 18px 50px rgba(23, 57, 95, .11);
}

#wpsg-tool .wpsg__field {
	min-width: 0;
}

#wpsg-tool .wpsg__field label,
#wpsg-tool .wpsg__field legend {
	display: block;
	margin: 0 0 8px;
	padding: 0;
	color: var(--wpsg-navy-deep);
	font-size: 14px;
	font-weight: 800;
}

#wpsg-tool .wpsg__url-row {
	display: flex;
	align-items: center;
	overflow: hidden;
	border: 2px solid #cbd8e6;
	border-radius: 13px;
	background: #fff;
	transition: border-color .2s, box-shadow .2s;
}

#wpsg-tool .wpsg__url-row:focus-within {
	border-color: var(--wpsg-navy);
	box-shadow: 0 0 0 4px rgba(23, 57, 95, .11);
}

#wpsg-tool .wpsg__url-row > span {
	flex: 0 0 auto;
	padding: 14px 0 14px 16px;
	color: #7b8998;
	font-weight: 700;
	white-space: nowrap;
}

#wpsg-tool input[type="text"],
#wpsg-tool select {
	width: 100%;
	height: 52px;
	margin: 0;
	padding: 0 14px;
	border: 1px solid #cbd8e6;
	border-radius: 12px;
	background: #fff;
	color: var(--wpsg-text);
	font: inherit;
	font-size: 16px;
}

#wpsg-tool .wpsg__url-row input[type="text"] {
	min-width: 0;
	height: 52px;
	padding-left: 2px;
	border: 0;
	border-radius: 0;
	outline: none;
}

#wpsg-tool select:focus {
	border-color: var(--wpsg-navy);
	outline: 3px solid rgba(23, 57, 95, .11);
}

#wpsg-tool .wpsg__help,
#wpsg-tool .wpsg__message {
	margin: 8px 0 0;
	color: var(--wpsg-muted);
	font-size: 13px;
}

#wpsg-tool .wpsg__message:empty {
	display: none;
}

#wpsg-tool .wpsg__message.is-error { color: #b42318; font-weight: 700; }
#wpsg-tool .wpsg__message.is-warning { color: #9a6700; font-weight: 700; }
#wpsg-tool .wpsg__message.is-success { color: #167348; font-weight: 700; }

#wpsg-tool .wpsg__grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 20px;
	margin-top: 24px;
}

#wpsg-tool fieldset {
	margin: 0;
	padding: 0;
	border: 0;
}

#wpsg-tool .wpsg__segments {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 7px;
	padding: 5px;
	border: 1px solid #cbd8e6;
	border-radius: 12px;
	background: #f4f7fa;
}

#wpsg-tool .wpsg__segments label {
	margin: 0;
	cursor: pointer;
}

#wpsg-tool .wpsg__segments input {
	position: absolute;
	opacity: 0;
	pointer-events: none;
}

#wpsg-tool .wpsg__segments span {
	display: grid;
	place-items: center;
	height: 40px;
	border-radius: 8px;
	color: var(--wpsg-muted);
}

#wpsg-tool .wpsg__segments input:checked + span {
	background: #fff;
	color: var(--wpsg-navy);
	box-shadow: 0 2px 8px rgba(23, 57, 95, .12);
}

#wpsg-tool .wpsg__segments input:focus-visible + span {
	outline: 3px solid rgba(23, 57, 95, .22);
}

#wpsg-tool .wpsg__preview {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 12px;
	margin-top: 24px;
	padding: 25px 18px;
	border: 1px dashed #bccbda;
	border-radius: 16px;
	background: var(--wpsg-cream);
	transition: background .2s;
}

#wpsg-tool .wpsg__preview.is-dark {
	background: #20242a;
}

#wpsg-tool .wpsg__preview-label {
	color: var(--wpsg-muted);
	font-size: 12px;
	font-weight: 800;
	letter-spacing: .08em;
	text-transform: uppercase;
}

#wpsg-tool .wpsg__preview.is-dark .wpsg__preview-label,
#wpsg-tool .wpsg__preview.is-dark small {
	color: #c5cbd2;
}

#wpsg-tool .wpsg__mock-button {
	display: inline-flex;
	align-items: center;
	gap: 9px;
	max-width: 100%;
	padding: 10px 17px;
	border: 1px solid #9da7b2;
	border-radius: 999px;
	background: #fff;
	color: #222;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.25;
}

#wpsg-tool .is-dark .wpsg__mock-button {
	border-color: #68717b;
	background: #30353c;
	color: #fff;
}

#wpsg-tool .wpsg__google-g {
	flex: 0 0 auto;
	width: 22px;
	height: 22px;
	display: block;
}

#wpsg-tool .wpsg__preview small {
	color: var(--wpsg-muted);
	text-align: center;
}

#wpsg-tool .wpsg__generate {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
	width: 100%;
	min-height: 58px;
	margin: 24px 0 0;
	padding: 12px 20px;
	border: 0;
	border-radius: 14px;
	background: var(--wpsg-yellow);
	color: var(--wpsg-navy-deep);
	font: inherit;
	font-size: 17px;
	font-weight: 900;
	cursor: pointer;
	overflow: hidden;
	box-shadow: 0 7px 0 #d8c336;
	transition: transform .15s, box-shadow .15s;
	animation: wpsg-generate-pulse 2.2s ease-in-out infinite;
}

#wpsg-tool .wpsg__generate::before {
	position: absolute;
	top: -45%;
	left: -28%;
	width: 22%;
	height: 190%;
	background: rgba(255, 255, 255, .75);
	content: "";
	transform: rotate(22deg);
	animation: wpsg-generate-shine 2.6s ease-in-out infinite;
}

#wpsg-tool .wpsg__generate > span {
	position: relative;
	z-index: 1;
}

@keyframes wpsg-generate-pulse {
	0%, 100% { box-shadow: 0 7px 0 #d8c336, 0 0 0 0 rgba(255, 232, 82, .42); }
	50% { box-shadow: 0 7px 0 #d8c336, 0 0 0 11px rgba(255, 232, 82, 0); }
}

@keyframes wpsg-generate-shine {
	0%, 35% { left: -28%; }
	65%, 100% { left: 118%; }
}

#wpsg-tool.wpsg--capture .wpsg__url-row,
#wpsg-tool.wpsg--capture #wpsg-platform,
#wpsg-tool.wpsg--capture .wpsg__generate {
	border-color: #e52521 !important;
	outline: 5px solid #e52521 !important;
	outline-offset: 4px;
	box-shadow: 0 0 0 10px rgba(229, 37, 33, .18), 0 10px 26px rgba(229, 37, 33, .24) !important;
}

#wpsg-tool .wpsg__generate:hover {
	transform: translateY(-2px);
	box-shadow: 0 9px 0 #d8c336;
}

#wpsg-tool .wpsg__generate:active {
	transform: translateY(4px);
	box-shadow: 0 3px 0 #d8c336;
}

#wpsg-tool .wpsg__result {
	margin-top: 28px;
	scroll-margin-top: 30px;
}

#wpsg-tool .wpsg__result[hidden] {
	display: none;
}

#wpsg-tool .wpsg__result-head,
#wpsg-tool .wpsg__code-head,
#wpsg-tool .wpsg__actions {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
}

#wpsg-tool .wpsg__result-head h3 {
	margin: 10px 0 0;
	font-size: clamp(22px, 3vw, 30px);
	line-height: 1.25;
}

#wpsg-tool .wpsg__platform-badge {
	flex: 0 0 auto;
	padding: 8px 13px;
	border-radius: 10px;
	background: var(--wpsg-blue-soft);
	color: var(--wpsg-navy);
	font-size: 13px;
	font-weight: 850;
}

#wpsg-tool .wpsg__notice {
	margin: 22px 0;
	padding: 15px 17px;
	border-left: 4px solid var(--wpsg-yellow);
	border-radius: 0 10px 10px 0;
	background: var(--wpsg-cream);
	font-size: 14px;
}

#wpsg-tool .wpsg__notice code {
	padding: 2px 5px;
	border-radius: 4px;
	background: #eef2f6;
	font-size: .9em;
}

#wpsg-tool .wpsg__code-card {
	overflow: hidden;
	margin-top: 16px;
	border: 1px solid #243b55;
	border-radius: 14px;
	background: #101c2b;
}

#wpsg-tool .wpsg__code-card--secondary {
	border-color: var(--wpsg-line);
	background: #f6f8fa;
}

#wpsg-tool .wpsg__code-head {
	padding: 12px 14px;
	color: #fff;
}

#wpsg-tool .wpsg__code-card--secondary .wpsg__code-head {
	color: var(--wpsg-navy-deep);
}

#wpsg-tool .wpsg__code-head > div {
	display: flex;
	flex-direction: column;
}

#wpsg-tool .wpsg__code-head small {
	color: #778799;
	font-size: 12px;
}

#wpsg-tool .wpsg__code-head button,
#wpsg-tool .wpsg__actions button,
#wpsg-tool .wpsg__actions a {
	flex: 0 0 auto;
	margin: 0;
	padding: 9px 13px;
	border: 1px solid rgba(255, 255, 255, .28);
	border-radius: 8px;
	background: rgba(255, 255, 255, .1);
	color: #fff;
	font: inherit;
	font-size: 13px;
	font-weight: 800;
	line-height: 1.2;
	cursor: pointer;
	text-decoration: none;
}

#wpsg-tool .wpsg__code-card--secondary .wpsg__code-head button {
	border-color: #cbd8e6;
	background: #fff;
	color: var(--wpsg-navy);
}

#wpsg-tool .wpsg__code-head button.is-copied {
	border-color: #48c78e;
	background: #167348;
	color: #fff;
}

#wpsg-tool pre {
	max-height: 330px;
	margin: 0;
	padding: 18px;
	overflow: auto;
	border: 0;
	background: #0b1420;
	color: #dcecff;
	font-size: 13px;
	line-height: 1.6;
	white-space: pre-wrap;
	word-break: break-word;
}

#wpsg-tool .wpsg__code-card--secondary pre {
	background: #fff;
	color: #25384c;
}

#wpsg-tool pre code {
	padding: 0;
	background: transparent;
	color: inherit;
	font: inherit;
}

#wpsg-tool .wpsg__actions {
	justify-content: flex-start;
	margin-top: 22px;
	flex-wrap: wrap;
}

#wpsg-tool .wpsg__actions a {
	border-color: var(--wpsg-navy);
	background: var(--wpsg-navy);
}

#wpsg-tool .wpsg__actions button {
	border-color: #cbd8e6;
	background: #fff;
	color: var(--wpsg-navy);
}

#wpsg-tool .wpsg__eligibility {
	margin: 20px 0 0;
	padding-top: 18px;
	border-top: 1px solid var(--wpsg-line);
	color: var(--wpsg-muted);
	font-size: 13px;
}

@media (max-width: 680px) {
	#wpsg-tool .wpsg__steps {
		gap: 4px;
	}

	#wpsg-tool .wpsg__steps li {
		flex-direction: column;
		gap: 4px;
		font-size: 12px;
	}

	#wpsg-tool .wpsg__grid {
		grid-template-columns: 1fr;
		gap: 17px;
	}

	#wpsg-tool .wpsg__form,
	#wpsg-tool .wpsg__result {
		border-radius: 18px;
	}

	#wpsg-tool .wpsg__result-head,
	#wpsg-tool .wpsg__code-head {
		align-items: flex-start;
	}

	#wpsg-tool .wpsg__result-head {
		flex-direction: column-reverse;
	}

	#wpsg-tool .wpsg__code-head strong {
		font-size: 14px;
	}

	#wpsg-tool .wpsg__code-head button {
		padding: 8px 10px;
	}

	#wpsg-tool .wpsg__url-row > span,
	#wpsg-tool input[type="text"] {
		font-size: 15px;
	}
}
