/* HW Email Signups — SMS Sign Up page ([hw_sms_signup]).
   Layout after the reference: lots of white space, a small spaced-out
   label, a large centred uppercase headline, the phone field and a solid
   black button side by side, and the SMS terms underneath. Fonts come from
   the theme so it stays in Hevy Weyt's typography. */

/* The page's own title is replaced by the headline below. */
.hwes-sms-page .hero-section,
.hwes-sms-page .entry-header {
	display: none !important;
}

.hwes-sms {
	--hwes-ink: #111111;
	--hwes-muted: #5c5c5c;
	--hwes-line: #cfcfcf;
	--hwes-error: #b3261e;
	max-width: 640px;
	margin: 0 auto;
	padding: clamp(72px, 14vh, 200px) 20px clamp(72px, 12vh, 160px);
	text-align: center;
	color: var(--hwes-ink);
	box-sizing: border-box;
}
.hwes-sms *,
.hwes-sms *::before,
.hwes-sms *::after {
	box-sizing: border-box;
}

.hwes-sms__eyebrow {
	margin: 0 0 clamp(36px, 7vh, 80px);
	font-size: 15px;
	font-weight: 600;
	letter-spacing: 0.22em;
	text-transform: uppercase;
	color: var(--hwes-ink);
}

.hwes-sms__title {
	margin: 0 auto clamp(36px, 6vh, 56px);
	max-width: 560px;
	font-size: clamp(30px, 5.2vw, 52px);
	line-height: 1.25;
	font-weight: 500;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: var(--hwes-ink);
	overflow-wrap: break-word;
}

.hwes-sms__form {
	text-align: left;
}

.hwes-sms__row {
	display: flex;
	gap: 14px;
	align-items: stretch;
}

.hwes-sms__field {
	flex: 1 1 auto;
	min-width: 0;
	display: flex;
	align-items: center;
	height: 72px;
	border: 1px solid var(--hwes-line);
	border-radius: 4px;
	background: #fff;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.hwes-sms__field:focus-within {
	border-color: var(--hwes-ink);
	box-shadow: 0 0 0 1px var(--hwes-ink);
}
.hwes-sms__field.is-invalid {
	border-color: var(--hwes-error);
	box-shadow: 0 0 0 1px var(--hwes-error);
}

.hwes-sms__country {
	flex: 0 0 auto;
	height: 100%;
	max-width: 116px;
	margin: 0;
	padding: 0 30px 0 16px;
	border: 0;
	border-right: 1px solid #ececec;
	border-radius: 4px 0 0 4px;
	background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%23111' stroke-width='1.8'/%3E%3C/svg%3E") no-repeat right 12px center;
	-webkit-appearance: none;
	appearance: none;
	font-size: 17px;
	color: var(--hwes-ink);
	cursor: pointer;
}
.hwes-sms__country:focus {
	outline: none;
}

.hwes-sms__phone {
	flex: 1 1 auto;
	min-width: 0;
	height: 100%;
	margin: 0;
	padding: 0 16px;
	border: 0 !important;
	border-radius: 0 4px 4px 0;
	background: transparent !important;
	box-shadow: none !important;
	font-size: 18px;
	letter-spacing: 0.02em;
	color: var(--hwes-ink);
}
.hwes-sms__phone:focus {
	outline: none;
}

.hwes-sms__button {
	flex: 0 0 auto;
	min-width: 158px;
	height: 72px;
	padding: 0 26px;
	border: 0;
	border-radius: 4px;
	background: #000;
	color: #fff;
	font-size: 18px;
	font-weight: 600;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	cursor: pointer;
	transition: opacity 0.15s ease;
}
.hwes-sms__button:hover,
.hwes-sms__button:focus-visible {
	opacity: 0.85;
}
.hwes-sms__button:focus-visible {
	outline: 2px solid #000;
	outline-offset: 3px;
}
.hwes-sms__button[disabled] {
	cursor: progress;
	opacity: 0.7;
}
.hwes-sms__button.is-loading .hwes-sms__button-label::after {
	content: "";
	display: inline-block;
	width: 14px;
	height: 14px;
	margin-left: 10px;
	vertical-align: -1px;
	border: 2px solid rgba(255, 255, 255, 0.35);
	border-top-color: #fff;
	border-radius: 50%;
	animation: hwes-spin 0.7s linear infinite;
}
@keyframes hwes-spin {
	to { transform: rotate(360deg); }
}

.hwes-sms__consent {
	display: flex;
	gap: 12px;
	align-items: flex-start;
	margin: 18px 0 0;
	cursor: pointer;
}
.hwes-sms__consent input {
	flex: 0 0 auto;
	width: 18px;
	height: 18px;
	margin: 2px 0 0;
	accent-color: #000;
	cursor: pointer;
}
.hwes-sms__consent.is-invalid input {
	outline: 2px solid var(--hwes-error);
	outline-offset: 2px;
}
.hwes-sms__terms {
	font-size: 14px;
	line-height: 1.6;
	color: var(--hwes-muted);
}
.hwes-sms__terms a {
	color: var(--hwes-ink);
	text-decoration: underline;
	text-underline-offset: 2px;
}

.hwes-sms__msg {
	min-height: 1.4em;
	margin: 14px 0 0;
	font-size: 15px;
	color: var(--hwes-error);
}
.hwes-sms__msg:empty {
	margin: 0;
	min-height: 0;
}

.hwes-sms__done {
	padding: 8px 0 0;
}
.hwes-sms__done:focus {
	outline: none;
}
.hwes-sms__done-title {
	margin: 0 0 12px;
	font-size: 22px;
	font-weight: 600;
	letter-spacing: 0.18em;
}
.hwes-sms__done-text {
	margin: 0 auto;
	max-width: 480px;
	font-size: 16px;
	line-height: 1.6;
	color: var(--hwes-muted);
}

.hwes-sms__sr,
.hwes-sms__hp {
	position: absolute !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
}

/* Phones: field on its own line, full-width button below. */
@media (max-width: 540px) {
	.hwes-sms__row {
		flex-direction: column;
		gap: 12px;
	}
	.hwes-sms__field,
	.hwes-sms__button {
		height: 60px;
	}
	.hwes-sms__button {
		width: 100%;
	}
	.hwes-sms__eyebrow {
		font-size: 13px;
	}
	.hwes-sms__terms {
		font-size: 13px;
	}
}
