/* ==========================================================================
   Subscribe Banner
   Figma: node 52422:6436
   ========================================================================== */

/* ── Section ── */

.subscribe-banner {
	padding: 100px 0;
	background: linear-gradient(
		192deg,
		rgba(245, 56,  56,  0.10) 0%,
		rgba(255, 212, 96,  0.10) 42%,
		rgba(253, 176, 87,  0.10) 100%
	);
}

/* ── Card ── */

.subscribe-banner__card {
	background: #fff;
	border-radius: 16px;
	box-shadow: 0 0 10px 0 rgba(204, 204, 204, 0.25);
	overflow: hidden;
	display: flex;
	align-items: center;
	gap: 48px;
	position: relative;
}

.subscribe-banner__card::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 52%;
    height: 100%;
    background: url(../images/card-grid.svg);
    background-size: cover;
    background-position: right center;
    background-repeat: no-repeat;
    z-index: 0;
}

/* ── Left column ── */

.subscribe-banner__left {
	padding: 48px 0 48px 48px;
	flex: 0 0 572px;
	max-width: 572px;
	display: flex;
	flex-direction: column;
	gap: 24px;
	position: relative;
	z-index: 1;
}

/* ── Text block ── */

.subscribe-banner__text {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.subscribe-banner__eyebrow {
	font-family: var(--font-figtree);
	font-size: 16px;
	font-weight: 700;
	color: #3978F2;
	line-height: 24px;
	letter-spacing: 0.032px;
	text-transform: uppercase;
	margin: 0;
}

.subscribe-banner__heading {
	font-family: var(--font-figtree);
	font-size: 24px;
	font-weight: 600;
	color: var(--nav-dark);
	line-height: 32px;
	letter-spacing: 0;
	margin: 0;
}

/* ── Form ── */

.subscribe-banner__form {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

/* Honeypot — visually hidden but NOT display:none (some bots skip those) */
.subscribe-banner__hp {
	position: absolute;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

/* Row: input + button */
.subscribe-banner__row {
	display: flex;
	align-items: flex-start;
	gap: 16px;
}

/* Field wrapper (holds input + error message) */
.subscribe-banner__field {
	flex: 1 1 0;
	min-width: 0;
	max-width: 320px;
	width: 100%;
	display: flex;
	flex-direction: column;
	gap: 16px;
}

/* ── Input ── */

.subscribe-banner__input {
	width: 100%;
	height: 48px;
	padding: 0 20px;
	border: 1px solid #EAECEE;
	border-radius: 8px;
	background: #fff;
	font-family: var(--font-figtree);
	font-size: 16px;
	font-weight: 400;
	color: var(--nav-dark);
	line-height: 24px;
	outline: none;
	transition: border-color 0.18s ease, box-shadow 0.18s ease;
	-webkit-appearance: none;
	appearance: none;
}

.subscribe-banner__input::placeholder {
	color: #848c97;
}

/* Focus */
.subscribe-banner__input:focus {
	border-color: #3978F2;
	box-shadow: 0 0 0 3px rgba(57, 120, 242, 0.12);
}

/* Valid (after interaction) */
.subscribe-banner__input:not(:placeholder-shown):valid {
	border-color: #EAECEE;
}

/* Error state — applied via JS */
.subscribe-banner__input.has-error {
	border-color: #F53838;
	box-shadow: 0 0 0 3px rgba(245, 56, 56, 0.10);
}

.subscribe-banner__input.has-error:focus {
	border-color: #F53838;
	box-shadow: 0 0 0 3px rgba(245, 56, 56, 0.15);
}

/* Error message */
.subscribe-banner__input-error {
	font-family: var(--font-figtree);
	font-size: 13px;
	font-weight: 400;
	color: #F53838;
	line-height: 18px;
	min-height: 0;
}

/* ── Button ── */

.subscribe-banner__btn {
	flex-shrink: 0;
	height: 48px;
	padding: 0 24px;
	border: none;
	border-radius: 8px;
	background: #3978F2;
	font-family: var(--font-figtree);
	font-size: 16px;
	font-weight: 600;
	color: #fff;
	letter-spacing: 0.032px;
	line-height: 24px;
	cursor: pointer;
	transition: background 0.18s ease, transform 0.1s ease;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	white-space: nowrap;
}

.subscribe-banner__btn:hover:not(:disabled) {
	background: #2D67E0;
}

.subscribe-banner__btn:active:not(:disabled) {
	background: #2558c8;
	transform: translateY(1px);
}

.subscribe-banner__btn:disabled {
	opacity: 0.65;
	cursor: not-allowed;
}

/* Spinner — shown while loading */
.subscribe-banner__btn-spinner {
	display: none;
	width: 16px;
	height: 16px;
	border: 2px solid rgba(255, 255, 255, 0.35);
	border-top-color: #fff;
	border-radius: 50%;
	animation: sub-spin 0.6s linear infinite;
	flex-shrink: 0;
}

.subscribe-banner__btn.is-loading .subscribe-banner__btn-label {
	opacity: 0.7;
}

.subscribe-banner__btn.is-loading .subscribe-banner__btn-spinner {
	display: block;
}

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

/* ── Disclaimer ── */

.subscribe-banner__disclaimer {
	font-family: var(--font-figtree);
	font-size: 14px;
	font-weight: 400;
	color: #848c97;
	line-height: 1;
	margin: 0;
}

/* ── Success message ── */

.subscribe-banner__success {
	display: flex;
	align-items: center;
	gap: 8px;
	font-family: var(--font-figtree);
	font-size: 15px;
	font-weight: 500;
	color: #3978F2;
	line-height: 24px;
}

.subscribe-banner__success[hidden] {
	display: none;
}

/* ── Right column (image) ── */

.subscribe-banner__right {
	flex: 1 1 0;
	min-width: 0;
	display: flex;
	align-items: flex-end;
	justify-content: center;
	align-self: stretch;
	z-index: 1;
}

.subscribe-banner__image {
    max-height: 270px;
    width: auto;
    height: 100%;
    display: block;
    object-fit: contain;
}

/* ── Responsive ── */
@media(max-width: 1200px) {
	.subscribe-banner__left {
		flex: 1 1 0;
	}
	.subscribe-banner__image {
		max-width: 100%;
		height: auto;
		max-height: unset;
	}
}
@media (max-width: 1100px) {
	.subscribe-banner__left {
		flex: 0 0 420px;
		max-width: 420px;
	}
}
@media (max-width: 992px) {
	.subscribe-banner__card::before {
		display: none;
	}
	.subscribe-banner__card {
		padding: 48px;
	}
	.subscribe-banner__right {
		display: none;
	}
	.subscribe-banner__left {
		max-width: 100%;
		padding: 0;
		flex: unset;
	}
}
@media (max-width: 900px) {
	.subscribe-banner__card {
		flex-direction: column;
		align-items: stretch;
		gap: 32px;
	}

	.subscribe-banner__left {
		flex: none;
		max-width: 100%;
	}

	.subscribe-banner__right {
		justify-content: center;
	}

	.subscribe-banner__image {
		max-height: 220px;
	}
}

@media (max-width: 600px) {
	.subscribe-banner__card {
		padding-top: 140px;
	}
	.subscribe-banner__card::after {
		content: '';
		position: absolute;
		top: -315px;
		left: 50%;
		transform: translateX(-50%);
		width: 407.158px;
		height: 407.158px;
		flex-shrink: 0;
		border-radius: 407.158px;
		background: linear-gradient(211deg, rgba(245, 56, 56, 0.50) 0%, rgba(255, 212, 96, 0.50) 41.67%, rgba(253, 176, 87, 0.50) 100%);
	}
	.subscribe-banner__heading {
		font-size: 20px;
		line-height: 28px;
	}

	.subscribe-banner__row {
		flex-direction: column;
		gap: 12px;
	}

	.subscribe-banner__btn {
		width: 100%;
		justify-content: center;
	}

	.subscribe-banner__right {
		display: none;
	}
	.subscribe-banner__field {
		max-width: 100%;
	}
}

/* ==========================================================================
   HubSpot embed overrides
   Scoped to #hs-subscribe-form and #hs-footer-form so HubSpot defaults
   do not leak into the rest of the page.
   ========================================================================== */

/* ── Layout: row (input + button side by side) ── */

#hs-subscribe-form .hs-form,
#hs-footer-form .hs-form {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	flex-wrap: wrap;
	gap: 16px;
	margin: 0;
}

#hs-subscribe-form .hs_email,
#hs-footer-form .hs_email {
	flex: 1 1 0;
	min-width: 0;
	max-width: 320px;
	margin: 0;
}

#hs-subscribe-form .hs_submit,
#hs-footer-form .hs_submit {
	flex-shrink: 0;
	margin: 0;
}

#hs-subscribe-form .hs-form-field,
#hs-footer-form .hs-form-field {
	margin: 0;
	width: 100%;
	max-width: 100%;
}

#hs-subscribe-form .input,
#hs-footer-form .input {
	margin: 0;
}

/* ── Label (screen-reader only) ── */

#hs-subscribe-form .hs-form-field > label,
#hs-footer-form .hs-form-field > label {
	position: absolute;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
}

/* ── Input ── */

#hs-subscribe-form .hs-input,
#hs-footer-form .hs-input {
	width: 100%;
	max-width: 400px;
	height: 48px;
	padding: 0 20px;
	border: 1px solid #EAECEE;
	border-radius: 8px;
	background: #fff;
	font-family: var(--font-figtree);
	font-size: 16px;
	font-weight: 400;
	color: var(--nav-dark);
	line-height: 24px;
	outline: none;
	box-shadow: none;
	transition: border-color 0.18s ease, box-shadow 0.18s ease;
	-webkit-appearance: none;
	appearance: none;
	margin: 0;
}

#hs-subscribe-form .hs-input::placeholder,
#hs-footer-form .hs-input::placeholder {
	color: #848c97;
}

#hs-subscribe-form .hs-input:focus,
#hs-footer-form .hs-input:focus {
	border-color: #3978F2;
	box-shadow: 0 0 0 3px rgba(57, 120, 242, 0.12);
}

#hs-subscribe-form .hs-input.error,
#hs-footer-form .hs-input.error {
	border-color: #F53838;
	box-shadow: 0 0 0 3px rgba(245, 56, 56, 0.10);
}

/* ── Error messages ── */

#hs-subscribe-form .hs-error-msgs,
#hs-footer-form .hs-error-msgs {
	list-style: none;
	margin: 4px 0 0;
	padding: 0;
}

#hs-subscribe-form .hs-error-msg,
#hs-footer-form .hs-error-msg {
	font-family: var(--font-figtree);
	font-size: 13px;
	font-weight: 400;
	color: #F53838;
	line-height: 18px;
}

/* ── Submit button ── */

#hs-subscribe-form .hs-button,
#hs-footer-form .hs-button {
	height: 48px;
	padding: 0 24px;
	border: none;
	border-radius: 8px;
	background: #3978F2;
	font-family: var(--font-figtree);
	font-size: 16px;
	font-weight: 600;
	color: #fff;
	letter-spacing: 0.032px;
	line-height: 24px;
	cursor: pointer;
	transition: background 0.18s ease, transform 0.1s ease;
	white-space: nowrap;
	-webkit-appearance: none;
	appearance: none;
}

#hs-subscribe-form .hs-button:hover,
#hs-footer-form .hs-button:hover {
	background: #2D67E0;
}

#hs-subscribe-form .hs-button:active,
#hs-footer-form .hs-button:active {
	background: #2558c8;
	transform: translateY(1px);
}

/* ── Hide HubSpot extra content ── */

/* Description richtext that HubSpot injects above the fields */
#hs-subscribe-form .hs-richtext,
#hs-footer-form .hs-richtext {
	display: none;
}

/* Hide all form fields except the email input */
#hs-subscribe-form .hs-form-field:not(.hs_email),
#hs-footer-form .hs-form-field:not(.hs_email) {
	display: none;
}

/* ── GDPR / legal consent ── */

#hs-subscribe-form .legal-consent-container,
#hs-footer-form .legal-consent-container {
	font-family: var(--font-figtree);
	font-size: 13px;
	color: #848c97;
	flex-basis: 100%;
}

#hs-footer-form {
	width: 100%;
}
#hs-footer-form .hs-form,
#hs-footer-form .input,
#hs-footer-form .hs-form-field {
	width: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
}
#hs-footer-form .input,
#hs-footer-form .hs-input {
	max-width: 575px;
}

/* ── Responsive ── */
@media (max-width: 600px) {
	#hs-subscribe-form .hs-form,
	#hs-footer-form .hs-form {
		flex-direction: column;
		gap: 12px;
	}

	#hs-subscribe-form .hs_email,
	#hs-footer-form .hs_email {
		max-width: 100%;
		width: 100%;
	}

	#hs-subscribe-form .hs-button,
	#hs-footer-form .hs-button {
		width: 100%;
	}
}
