/**
 * Sober Dispatch Newsletter Styles
 * Pixel-perfect match to Sober Standard branding with 100% all-device and Elementor responsiveness.
 */

/* Wrapper - robust display inside Elementor and standard themes */
.sober-dispatch-wrapper {
	display: block !important;
	width: 100% !important;
	max-width: 580px !important;
	min-width: 260px;
	margin: 20px auto !important;
	padding: 0 !important;
	box-sizing: border-box !important;
}

/* Ensure full width inside Elementor containers */
.elementor-widget-shortcode .sober-dispatch-wrapper,
.elementor-shortcode .sober-dispatch-wrapper {
	width: 100% !important;
}

.sober-dispatch-form {
	display: block !important;
	width: 100% !important;
	margin: 0 !important;
	padding: 0 !important;
	box-sizing: border-box !important;
}

/* The outer bordered container box matching the screenshot */
.sober-dispatch-box {
	display: flex !important;
	flex-direction: row !important;
	align-items: stretch !important;
	width: 100% !important;
	min-width: 260px !important;
	border: 1px solid #000000 !important;
	background-color: #ffffff !important;
	border-radius: 0 !important;
	overflow: hidden !important;
	box-sizing: border-box !important;
	min-height: 48px !important;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.sober-dispatch-box:focus-within {
	border-color: #000000 !important;
	box-shadow: 0 0 0 1px #000000 !important;
}

/* Input field */
.sober-dispatch-input {
	flex: 1 1 auto !important;
	min-width: 140px !important;
	width: 100% !important;
	height: auto !important;
	min-height: 48px !important;
	padding: 12px 18px !important;
	margin: 0 !important;
	border: none !important;
	outline: none !important;
	box-shadow: none !important;
	background-color: #ffffff !important;
	color: #111111 !important;
	font-family: inherit !important;
	font-size: 16px !important; /* 16px prevents iOS Safari auto-zoom on mobile */
	line-height: 1.4 !important;
	border-radius: 0 !important;
	-webkit-appearance: none !important;
	-moz-appearance: none !important;
	appearance: none !important;
	box-sizing: border-box !important;
}

.sober-dispatch-input::placeholder {
	color: #7b848c !important;
	opacity: 1 !important;
	font-family: inherit !important;
	font-weight: 400 !important;
	font-size: 15px !important;
}

.sober-dispatch-input:-ms-input-placeholder {
	color: #7b848c !important;
	font-size: 15px !important;
}

.sober-dispatch-input::-ms-input-placeholder {
	color: #7b848c !important;
	font-size: 15px !important;
}

.sober-dispatch-input:focus {
	outline: none !important;
	box-shadow: none !important;
	background-color: #ffffff !important;
}

/* Submit button */
.sober-dispatch-submit {
	flex: 0 0 auto !important;
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	min-height: 48px !important;
	padding: 0 24px !important;
	margin: 0 !important;
	border: none !important;
	border-left: 1px solid #000000 !important;
	outline: none !important;
	border-radius: 0 !important;
	background-color: #000000 !important;
	color: #ffffff !important;
	font-family: inherit !important;
	font-size: 14px !important;
	font-weight: 700 !important;
	letter-spacing: 0.5px !important;
	text-transform: uppercase !important;
	cursor: pointer !important;
	transition: background-color 0.2s ease, opacity 0.2s ease;
	box-sizing: border-box !important;
	line-height: 1 !important;
	text-decoration: none !important;
	white-space: nowrap !important;
	-webkit-appearance: none !important;
	-moz-appearance: none !important;
	appearance: none !important;
}

.sober-dispatch-submit:hover {
	background-color: #222222 !important;
	color: #ffffff !important;
}

.sober-dispatch-submit:active {
	background-color: #333333 !important;
}

.sober-dispatch-submit:disabled {
	opacity: 0.7 !important;
	cursor: not-allowed !important;
}

/* Feedback message notification */
.sober-dispatch-message {
	margin-top: 10px !important;
	padding: 12px 16px !important;
	font-size: 14px !important;
	line-height: 1.4 !important;
	box-sizing: border-box !important;
	border-radius: 0 !important;
	transition: all 0.3s ease;
}

.sober-dispatch-message.is-success {
	background-color: #f7f9f7 !important;
	border: 1px solid #2e7d32 !important;
	color: #1b5e20 !important;
	font-weight: 500 !important;
}

.sober-dispatch-message.is-error {
	background-color: #fff9f9 !important;
	border: 1px solid #d32f2f !important;
	color: #c62828 !important;
	font-weight: 500 !important;
}

/* ==========================================================================
   Responsive Breakpoints: Tablets, Mobile Devices & Narrow Columns
   ========================================================================== */

/* Tablet & Medium Screen optimization (481px to 640px) */
@media screen and (max-width: 640px) {
	.sober-dispatch-submit {
		padding: 0 18px !important;
		font-size: 13px !important;
	}
	.sober-dispatch-input {
		padding: 12px 14px !important;
	}
}

/* Mobile Devices (<= 480px) and Small Screens (iPhone, Android 320px - 414px) */
@media screen and (max-width: 480px) {
	.sober-dispatch-box {
		flex-direction: column !important;
		min-height: auto !important;
	}

	.sober-dispatch-input {
		width: 100% !important;
		border-bottom: 1px solid #000000 !important;
		padding: 14px 16px !important;
		text-align: left;
	}

	.sober-dispatch-submit {
		width: 100% !important;
		border-left: none !important;
		min-height: 48px !important;
		padding: 14px 20px !important;
		text-align: center;
		font-size: 14px !important;
	}
}

/* ==========================================================================
   Light Theme: For Dark / Black Backgrounds
   - White button with black text: [ JOIN THE DISPATCH ]
   - Crisp white border around the container
   - White input with black text & black divider
   ========================================================================== */
.sober-dispatch-wrapper.theme-light .sober-dispatch-box {
	border: 1px solid #ffffff !important;
	background-color: #ffffff !important;
}

.sober-dispatch-wrapper.theme-light .sober-dispatch-box:focus-within {
	border-color: #ffffff !important;
	box-shadow: 0 0 0 1px #ffffff !important;
}

.sober-dispatch-wrapper.theme-light .sober-dispatch-input {
	background-color: #ffffff !important;
	color: #111111 !important;
	border: none !important;
}

.sober-dispatch-wrapper.theme-light .sober-dispatch-submit {
	background-color: #ffffff !important;
	color: #000000 !important;
	border-left: 1px solid #000000 !important;
	font-weight: 700 !important;
}

.sober-dispatch-wrapper.theme-light .sober-dispatch-submit:hover {
	background-color: #e5e5e5 !important;
	color: #000000 !important;
}

.sober-dispatch-wrapper.theme-light .sober-dispatch-submit:active {
	background-color: #cccccc !important;
}

@media screen and (max-width: 480px) {
	.sober-dispatch-wrapper.theme-light .sober-dispatch-submit {
		border-left: none !important;
		border-top: 1px solid #000000 !important;
	}
}
