/**
 * Uutiskirje-nauha + MC4WP-lomake.
 * Ladataan erikseen, koska build/main.css syntyy vasta `npm run build` -ajosta.
 * Pidä linjassa assets/main.scss:n NEWSLETTER-osion kanssa.
 */

.newsletter-band,
.site-newsletter-band .newsletter-band {
	margin: 0 !important;
	border-top: 1px solid rgba(0, 0, 0, 0.06);
}

.newsletter-band__inner,
.site-newsletter-band .newsletter-band__inner {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	gap: 1.5rem;
	width: 100%;
	max-width: 100%;
	box-sizing: border-box;
	padding-left: max(1rem, env(safe-area-inset-left));
	padding-right: max(1rem, env(safe-area-inset-right));
}

.newsletter-band__title,
.site-newsletter-band .newsletter-band__title {
	margin: 0 !important;
	font-size: clamp(1.25rem, 2.8vw, 1.5rem) !important;
	font-weight: 500;
	color: #277faf !important;
	line-height: 1.25;
	text-align: center;
	width: 100%;
	letter-spacing: -0.02em;
}

.newsletter-band .mc4wp-form,
.site-newsletter-band .mc4wp-form {
	margin: 0;
	width: 100%;
	max-width: 520px;
	padding: 1.5rem 1.5rem 1.375rem;
	background: #fff;
	border: 1px solid rgba(39, 127, 175, 0.12);
	border-radius: 16px;
	box-shadow:
		0 1px 2px rgba(0, 0, 0, 0.04),
		0 8px 32px rgba(39, 127, 175, 0.1);
	box-sizing: border-box;
}

@media (max-width: 520px) {
	.newsletter-band .mc4wp-form,
	.site-newsletter-band .mc4wp-form {
		padding: 1.25rem 1.125rem 1.125rem;
		border-radius: 14px;
	}
}

.newsletter-band .mc4wp-form-fields,
.site-newsletter-band .mc4wp-form-fields {
	display: flex;
	flex-direction: row;
	flex-wrap: wrap;
	align-items: flex-end;
	justify-content: flex-start;
	gap: 0.75rem 0.875rem;
	width: 100%;
}

.newsletter-band .mc4wp-form-fields > p,
.site-newsletter-band .mc4wp-form-fields > p {
	margin: 0;
}

.newsletter-band .mc4wp-form-fields > p:first-of-type,
.site-newsletter-band .mc4wp-form-fields > p:first-of-type {
	flex: 1 1 200px;
	max-width: 100%;
	min-width: min(100%, 180px);
}

.newsletter-band .mc4wp-form-fields > p:last-of-type,
.site-newsletter-band .mc4wp-form-fields > p:last-of-type {
	flex: 0 0 auto;
	display: flex;
	align-items: stretch;
}

.newsletter-band .mc4wp-form label,
.site-newsletter-band .mc4wp-form label {
	display: flex;
	flex-direction: column;
	align-items: stretch;
	gap: 0.4rem;
	text-align: left;
	font-size: 0.6875rem;
	font-weight: 600;
	color: #828282;
	line-height: 1.2;
	text-transform: uppercase;
	letter-spacing: 0.09em;
}

.newsletter-band .mc4wp-form input[type="email"],
.site-newsletter-band .mc4wp-form input[type="email"] {
	display: block !important;
	width: 100% !important;
	min-width: 0;
	box-sizing: border-box;
	height: 48px;
	border: 1px solid #e6e6e6 !important;
	background: #f8f8f8;
	color: #2c2c2c;
	padding: 0 1.125rem;
	border-radius: 12px;
	font-size: 1rem;
	line-height: 1.2;
	font-family: inherit;
	outline: none;
	-webkit-appearance: none;
	appearance: none;
	transition:
		border-color 0.2s ease,
		background-color 0.2s ease,
		box-shadow 0.2s ease;
}

.newsletter-band .mc4wp-form input[type="email"]::placeholder,
.site-newsletter-band .mc4wp-form input[type="email"]::placeholder {
	color: #828282;
	opacity: 1;
}

.newsletter-band .mc4wp-form input[type="email"]:hover,
.site-newsletter-band .mc4wp-form input[type="email"]:hover {
	border-color: #d4d4d4 !important;
	background: #fff;
}

.newsletter-band .mc4wp-form input[type="email"]:focus,
.site-newsletter-band .mc4wp-form input[type="email"]:focus {
	border-color: #277faf !important;
	background: #fff;
	box-shadow: 0 0 0 3px rgba(39, 127, 175, 0.18);
}

.newsletter-band .mc4wp-form input[type="submit"],
.newsletter-band .mc4wp-form button[type="submit"],
.site-newsletter-band .mc4wp-form input[type="submit"],
.site-newsletter-band .mc4wp-form button[type="submit"] {
	display: inline-block !important;
	box-sizing: border-box;
	min-width: 7.5rem;
	background: linear-gradient(180deg, #3088bc 0%, #277faf 100%);
	color: #fff !important;
	border: 1px solid rgba(0, 0, 0, 0.06) !important;
	padding: 0 1.375rem;
	min-height: 48px;
	height: 48px;
	border-radius: 12px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.07em;
	font-size: 0.8125rem;
	font-family: inherit;
	cursor: pointer;
	line-height: 1;
	box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
	transition:
		background 0.2s ease,
		border-color 0.2s ease,
		box-shadow 0.2s ease,
		transform 0.15s ease;
	white-space: nowrap;
	-webkit-appearance: none;
	appearance: none;
}

.newsletter-band .mc4wp-form input[type="submit"]:hover,
.newsletter-band .mc4wp-form button[type="submit"]:hover,
.site-newsletter-band .mc4wp-form input[type="submit"]:hover,
.site-newsletter-band .mc4wp-form button[type="submit"]:hover {
	background: linear-gradient(180deg, #2469a8 0%, #1c5ba3 100%);
	border-color: rgba(0, 0, 0, 0.08) !important;
	box-shadow: 0 4px 14px rgba(39, 127, 175, 0.35);
}

.newsletter-band .mc4wp-form input[type="submit"]:focus-visible,
.newsletter-band .mc4wp-form button[type="submit"]:focus-visible,
.site-newsletter-band .mc4wp-form input[type="submit"]:focus-visible,
.site-newsletter-band .mc4wp-form button[type="submit"]:focus-visible {
	outline: none;
	box-shadow:
		0 0 0 3px rgba(39, 127, 175, 0.25),
		0 4px 14px rgba(39, 127, 175, 0.25);
}

.newsletter-band .mc4wp-form input[type="submit"]:active,
.newsletter-band .mc4wp-form button[type="submit"]:active,
.site-newsletter-band .mc4wp-form input[type="submit"]:active,
.site-newsletter-band .mc4wp-form button[type="submit"]:active {
	transform: translateY(1px);
	box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
}

.newsletter-band .mc4wp-response,
.site-newsletter-band .mc4wp-response {
	margin-top: 1rem;
	padding-top: 1rem;
	border-top: 1px solid #e6e6e6;
	text-align: center;
	font-size: 0.875rem;
	line-height: 1.45;
}

.newsletter-band .mc4wp-alert,
.site-newsletter-band .mc4wp-alert {
	margin: 0;
	padding: 0.625rem 0.75rem;
	border-radius: 10px;
	font-size: 0.875rem;
	line-height: 1.4;
	text-align: center;
}

.newsletter-band .mc4wp-alert.mc4wp-success,
.site-newsletter-band .mc4wp-alert.mc4wp-success {
	background: rgba(42, 157, 143, 0.12);
	color: #247a6f;
	border: 1px solid rgba(42, 157, 143, 0.25);
}

.newsletter-band .mc4wp-alert.mc4wp-error,
.site-newsletter-band .mc4wp-alert.mc4wp-error {
	background: rgba(231, 111, 81, 0.1);
	color: #c24e32;
	border: 1px solid rgba(231, 111, 81, 0.28);
}

@media (max-width: 520px) {
	.newsletter-band .mc4wp-form-fields,
	.site-newsletter-band .mc4wp-form-fields {
		flex-direction: column;
		align-items: stretch;
	}

	.newsletter-band .mc4wp-form-fields > p:first-of-type,
	.newsletter-band .mc4wp-form-fields > p:last-of-type,
	.site-newsletter-band .mc4wp-form-fields > p:first-of-type,
	.site-newsletter-band .mc4wp-form-fields > p:last-of-type {
		flex: 1 1 auto;
		min-width: 0;
		width: 100%;
	}

	.newsletter-band .mc4wp-form input[type="submit"],
	.newsletter-band .mc4wp-form button[type="submit"],
	.site-newsletter-band .mc4wp-form input[type="submit"],
	.site-newsletter-band .mc4wp-form button[type="submit"] {
		width: 100%;
		min-width: 0;
		text-align: center;
	}
}
