/*
 * GP Contact Form + Contact section
 * Theme-independent: every value comes from the tokens below, so a theme
 * change only needs these remapped (if at all). Selectors are two classes deep
 * to win over theme element styles like `.entry-content h2` or `input[type=text]`.
 */

.gp-cs,
.gpcf {
	--gp-navy: #0f2a43;
	--gp-ink: #133453;
	--gp-slate: #587089;
	--gp-cyan: #0ebfe5;
	--gp-cyan-soft: #e0fcff;
	--gp-panel: #f5f7fa;
	--gp-line: #e3e8ef;
	--gp-field: #7a8fa6;
	--gp-white: #ffffff;
	--gp-error: #c53030;
	--gp-error-ink: #9b1c1c;
	--gp-error-bg: #fdecec;
	--gp-error-line: #f3b9b9;

	--gp-font-body: "Jost", system-ui, -apple-system, "Segoe UI", sans-serif;
	--gp-font-head: "Poppins", system-ui, -apple-system, "Segoe UI", sans-serif;
	--gp-font-display: "Stardos Stencil", Georgia, serif;

	/* Button pair. White on cyan fails contrast, so text is navy; hover flips to navy/white. */
	--gp-btn-bg: var(--gp-cyan);
	--gp-btn-fg: var(--gp-navy);
	--gp-btn-bg-hover: var(--gp-navy);
	--gp-btn-fg-hover: var(--gp-white);

	--gp-radius-card: 16px;
	--gp-radius-field: 8px;
	--gp-focus: 0 0 0 3px rgba(14, 191, 229, 0.45);
}

/* ---------- Contact section (block pattern) ---------- */

.gp-cs {
	box-sizing: border-box;
	padding: clamp(56px, 8vw, 96px) clamp(16px, 4vw, 24px) clamp(64px, 9vw, 112px);
	background: var(--gp-white);
	color: var(--gp-ink);
	font-family: var(--gp-font-body);
}

.gp-cs *,
.gp-cs *::before,
.gp-cs *::after {
	box-sizing: border-box;
}

/* Classic themes wrap group children in an inner container; let our layout ignore it. */
.gp-cs .wp-block-group__inner-container {
	display: contents;
}

.gp-cs .gp-cs__inner {
	max-width: 1160px;
	margin: 0 auto;
}

.gp-cs .gp-cs__head {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 20px;
	margin: 0;
	text-align: center;
}

.gp-cs .gp-cs__title {
	margin: 0;
	font-family: var(--gp-font-display);
	font-size: clamp(40px, 6vw, 56px);
	font-weight: 700;
	line-height: 1.1;
	letter-spacing: 1px;
	text-transform: uppercase;
	color: var(--gp-navy);
}

.gp-cs .gp-cs__title::after {
	content: "";
	display: block;
	width: 64px;
	height: 4px;
	margin: 20px auto 0;
	border-radius: 2px;
	background: var(--gp-cyan);
}

.gp-cs .gp-cs__intro {
	max-width: 560px;
	margin: 0;
	font-size: 20px;
	line-height: 1.6;
	color: var(--gp-slate);
}

.gp-cs .gp-cs__grid {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-start;
	gap: 40px;
	margin: 64px 0 0;
}

.gp-cs .gp-cs__main {
	flex: 1 1 560px;
	min-width: 0;
	margin: 0;
}

.gp-cs .gp-cs__aside {
	display: flex;
	flex: 1 1 320px;
	flex-direction: column;
	gap: 20px;
	min-width: 0;
	margin: 0;
}

.gp-cs .gp-cs__card {
	display: flex;
	flex-direction: column;
	gap: 16px;
	margin: 0;
	padding: 32px;
	border: 1px solid var(--gp-line);
	border-radius: var(--gp-radius-card);
	background: var(--gp-white);
}

.gp-cs .gp-cs__card > *,
.gp-cs .gp-cs__card .wp-block-buttons {
	margin: 0;
}

.gp-cs .gp-cs__card-title {
	display: flex;
	align-items: center;
	gap: 16px;
	margin: 0;
	font-family: var(--gp-font-head);
	font-size: 26px;
	font-weight: 700;
	line-height: 1.2;
	letter-spacing: 0;
	text-transform: uppercase;
	color: var(--gp-navy);
}

.gp-cs .gp-cs__card-title::before {
	content: "";
	flex: none;
	width: 56px;
	height: 56px;
	border-radius: 14px;
	background: var(--gp-cyan-soft) var(--gp-icon, none) center / 26px 26px no-repeat;
}

.gp-cs .gp-cs__icon-phone {
	--gp-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230f2a43' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72 12.84 12.84 0 0 0 .7 2.81 2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45 12.84 12.84 0 0 0 2.81.7A2 2 0 0 1 22 16.92z'/%3E%3C/svg%3E");
}

.gp-cs .gp-cs__icon-chat {
	--gp-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230f2a43' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z'/%3E%3C/svg%3E");
}

.gp-cs .gp-cs__phone {
	margin: 0;
	font-family: var(--gp-font-head);
	font-size: 30px;
	font-weight: 600;
	line-height: 1.3;
}

.gp-cs .gp-cs__phone a {
	color: var(--gp-navy);
	text-decoration: underline;
	text-decoration-color: var(--gp-cyan);
	text-decoration-thickness: 3px;
	text-underline-offset: 7px;
	transition: text-decoration-color 0.15s ease;
}

.gp-cs .gp-cs__phone a:hover {
	color: var(--gp-navy);
	text-decoration-color: var(--gp-navy);
}

.gp-cs .gp-cs__phone a:focus-visible {
	border-radius: 4px;
	outline: 3px solid var(--gp-cyan);
	outline-offset: 4px;
}

.gp-cs .gp-cs__muted {
	margin: 0;
	font-size: 17px;
	line-height: 1.5;
	color: var(--gp-slate);
}

.gp-cs .gp-cs__fb .wp-block-button__link {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	min-height: 48px;
	padding: 0 24px;
	border: 0;
	border-radius: 999px;
	background: var(--gp-btn-bg);
	box-shadow: none;
	color: var(--gp-btn-fg);
	font-family: var(--gp-font-body);
	font-size: 17px;
	font-weight: 600;
	line-height: 1;
	letter-spacing: 0;
	text-decoration: none;
	text-transform: none;
	transition: background-color 0.15s ease, color 0.15s ease;
}

.gp-cs .gp-cs__fb .wp-block-button__link::after {
	content: "";
	width: 18px;
	height: 18px;
	background: currentColor;
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.25' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M15 3h6v6M10 14 21 3M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6'/%3E%3C/svg%3E") center / contain no-repeat;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.25' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M15 3h6v6M10 14 21 3M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6'/%3E%3C/svg%3E") center / contain no-repeat;
}

.gp-cs .gp-cs__fb .wp-block-button__link:hover {
	background: var(--gp-btn-bg-hover);
	color: var(--gp-btn-fg-hover);
}

.gp-cs .gp-cs__fb .wp-block-button__link:focus-visible {
	outline: 3px solid var(--gp-navy);
	outline-offset: 3px;
}

/* ---------- Form card ---------- */

.gpcf {
	box-sizing: border-box;
	padding: clamp(24px, 4vw, 40px);
	border: 1px solid var(--gp-line);
	border-radius: var(--gp-radius-card);
	background: var(--gp-panel);
	color: var(--gp-ink);
	font-family: var(--gp-font-body);
}

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

.gpcf [hidden] {
	display: none !important;
}

.gpcf .gpcf-form {
	display: flex;
	flex-direction: column;
	gap: 24px;
	margin: 0;
}

.gpcf .gpcf-head {
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.gpcf .gpcf-title {
	margin: 0;
	font-family: var(--gp-font-head);
	font-size: 24px;
	font-weight: 700;
	line-height: 1.3;
	letter-spacing: 0;
	text-transform: uppercase;
	color: var(--gp-navy);
}

.gpcf .gpcf-note {
	margin: 0;
	font-size: 16px;
	line-height: 1.5;
	color: var(--gp-slate);
}

.gpcf .gpcf-req {
	color: var(--gp-error);
}

.gpcf .gpcf-row {
	display: flex;
	flex-wrap: wrap;
	gap: 24px;
}

.gpcf .gpcf-row > .gpcf-field {
	flex: 1 1 220px;
}

.gpcf .gpcf-field {
	display: flex;
	flex-direction: column;
	gap: 8px;
	min-width: 0;
	margin: 0;
}

.gpcf .gpcf-label {
	display: block;
	margin: 0;
	font-family: var(--gp-font-body);
	font-size: 17px;
	font-weight: 500;
	line-height: 1.4;
	color: var(--gp-ink);
}

.gpcf .gpcf-input {
	display: block;
	width: 100%;
	height: 54px;
	margin: 0;
	padding: 0 16px;
	border: 1.5px solid var(--gp-field);
	border-radius: var(--gp-radius-field);
	background: var(--gp-white);
	box-shadow: none;
	color: var(--gp-navy);
	font-family: var(--gp-font-body);
	font-size: 18px;
	line-height: 1.4;
	-webkit-appearance: none;
	appearance: none;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.gpcf .gpcf-textarea {
	height: auto;
	min-height: 168px;
	padding: 14px 16px;
	line-height: 1.5;
	resize: vertical;
}

.gpcf .gpcf-input:hover {
	border-color: var(--gp-ink);
}

.gpcf .gpcf-input:focus {
	border-color: var(--gp-navy);
	outline: none;
	box-shadow: var(--gp-focus);
}

.gpcf .gpcf-input[aria-invalid="true"] {
	border-width: 2px;
	border-color: var(--gp-error);
}

.gpcf .gpcf-input[aria-invalid="true"]:focus {
	box-shadow: 0 0 0 3px rgba(197, 48, 48, 0.25);
}

.gpcf .gpcf-error {
	margin: 0;
	font-size: 15px;
	line-height: 1.4;
	color: var(--gp-error-ink);
}

.gpcf .gpcf-alert {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	margin: 0;
	padding: 14px 16px;
	border: 1px solid var(--gp-error-line);
	border-radius: 10px;
	background: var(--gp-error-bg);
	color: var(--gp-error-ink);
	font-size: 16px;
	line-height: 1.45;
	outline: none;
}

.gpcf .gpcf-alert::before {
	content: "";
	flex: none;
	width: 20px;
	height: 20px;
	margin-top: 2px;
	background: currentColor;
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M12 8v4M12 16h.01'/%3E%3C/svg%3E") center / contain no-repeat;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M12 8v4M12 16h.01'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* Honeypot: off-screen, not display:none (some bots skip hidden fields). */
.gpcf .gpcf-hp {
	position: absolute !important;
	left: -10000px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.gpcf .gpcf-actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
	margin-top: 4px;
}

.gpcf .gpcf-turnstile-wrap {
	display: flex;
	flex-direction: column;
	gap: 8px;
	min-width: 0;
}

.gpcf .gpcf-turnstile {
	min-height: 65px;
}

.gpcf .gpcf-submit {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	height: 56px;
	margin: 0;
	padding: 0 36px;
	border: 0;
	border-radius: 999px;
	background: var(--gp-btn-bg);
	box-shadow: none;
	color: var(--gp-btn-fg);
	font-family: var(--gp-font-head);
	font-size: 16px;
	font-weight: 700;
	line-height: 1;
	letter-spacing: 0.5px;
	text-transform: uppercase;
	cursor: pointer;
	transition: background-color 0.15s ease, color 0.15s ease;
}

.gpcf .gpcf-submit:hover:not(:disabled) {
	background: var(--gp-btn-bg-hover);
	color: var(--gp-btn-fg-hover);
}

.gpcf .gpcf-submit:focus-visible {
	outline: 3px solid var(--gp-navy);
	outline-offset: 3px;
}

.gpcf .gpcf-submit:disabled {
	opacity: 0.75;
	cursor: progress;
}

.gpcf .gpcf-submit svg {
	flex: none;
}

.gpcf .gpcf-spinner {
	display: none;
	width: 20px;
	height: 20px;
	border: 2.5px solid currentColor;
	border-right-color: transparent;
	border-radius: 50%;
	animation: gpcf-spin 0.8s linear infinite;
}

.gpcf .gpcf-submit.is-loading .gpcf-spinner {
	display: inline-block;
}

.gpcf .gpcf-submit.is-loading .gpcf-arrow {
	display: none;
}

@keyframes gpcf-spin {
	to {
		transform: rotate(360deg);
	}
}

.gpcf .gpcf-noscript {
	margin: 0;
	font-size: 16px;
	color: var(--gp-error-ink);
}

.gpcf .gpcf-notice {
	margin: 0 0 24px;
	padding: 12px 16px;
	border: 1px solid #e0b252;
	border-radius: 8px;
	background: #fff8e1;
	color: #5c4400;
	font-size: 15px;
	line-height: 1.45;
}

/* ---------- Success ---------- */

.gpcf .gpcf-success {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 16px;
	padding: 24px 8px;
	text-align: center;
	outline: none;
}

.gpcf .gpcf-success-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 64px;
	height: 64px;
	border-radius: 999px;
	background: var(--gp-cyan);
	color: var(--gp-navy);
}

.gpcf .gpcf-success-title {
	margin: 0;
	font-family: var(--gp-font-head);
	font-size: 24px;
	font-weight: 700;
	line-height: 1.3;
	text-transform: uppercase;
	color: var(--gp-navy);
}

.gpcf .gpcf-success-text {
	max-width: 420px;
	margin: 0;
	font-size: 17px;
	line-height: 1.55;
	color: var(--gp-slate);
}

.gpcf .gpcf-success-text a {
	color: var(--gp-navy);
	font-weight: 600;
	text-decoration: underline;
	text-decoration-color: var(--gp-cyan);
	text-decoration-thickness: 2px;
	text-underline-offset: 4px;
}

@media (prefers-reduced-motion: reduce) {
	.gp-cs *,
	.gpcf * {
		transition: none !important;
	}

	.gpcf .gpcf-spinner {
		animation-duration: 2s;
	}
}

/* Block editor preview: Turnstile does not run there. */
.editor-styles-wrapper .gpcf .gpcf-turnstile {
	width: 300px;
	border: 1.5px dashed var(--gp-field);
	border-radius: 6px;
	background: var(--gp-white);
}
