/**
 * Affinite Product Stock Alert - Public Styles
 *
 * BEM methodology with prefix affinite-product-stock-alert-
 *
 * @package Affinite\ProductStockAlert
 * @since 1.0.0
 */

/* Button Container */
.affinite-product-stock-alert-button-container {
	display: flex;
	justify-content: center;
	padding: 30px 0 0 0;
}

/* Button */
.woocommerce .product .affinite-product-stock-alert-button {
	cursor: pointer;
	display: inline-block;
	text-align: center;
	padding: 20px 40px !important;
	border: none;
	border-radius: 100px;
	background-color: #FFE92F;
	color: #2B3838 !important;
	font-size: 14px;
	font-weight: 700;
	line-height: 14px !important;
	letter-spacing: 1px;
	text-transform: uppercase;
	opacity: 1 !important;
	transition: background-color 0.3s ease;
}

.woocommerce .product .affinite-product-stock-alert-button:hover {
	background-color: #FFEF6D !important;
}

/* Popup Modal */
.affinite-popup-alert-stock {
	display: none;
	position: fixed;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	z-index: 100000;
	background: #fff;
	border-bottom: 1px solid #aaa;
	border-radius: 4px;
	box-shadow: 0 3px 9px rgba(0, 0, 0, 0.5);
	-moz-box-shadow: 0 3px 9px rgba(0, 0, 0, 0.5);
	-webkit-box-shadow: 0 3px 9px rgba(0, 0, 0, 0.5);
	max-width: 500px;
	width: 80%;
	max-height: 90vh;
	overflow-y: auto;
}

.affinite-popup-alert-stock[style*="display: block"] {
	display: block !important;
}

/* Popup Header */
.affinite-popup-alert-stock header {
	padding: 12px 20px;
	border-bottom: 1px solid #e1e3e4;
	position: relative;
}

.affinite-popup-alert-stock__title {
	margin: 0;
	padding: 0 20px;
	color: #000;
	width: 100%;
	text-align: center;
}

/* Popup Body */
.affinite-popup-alert-stock__body {
	padding: 20px 20px 0 20px;
}

.affinite-popup-alert-stock__body ul {
	list-style: none;
	margin: 0;
	padding: 0;
}

.affinite-popup-alert-stock__body ul li {
	list-style: none;
	margin: 0 0 20px 0;
	padding: 0;
}

.affinite-popup-alert-stock__body label {
	display: none;
}

.affinite-popup-alert-stock__body input[type="text"],
.affinite-popup-alert-stock__body input[type="email"] {
	width: 100%;
	padding: 10px;
	border-radius: 8px;
	border: 1px solid #eaebeb;
	box-sizing: border-box;
}

.affinite-popup-alert-stock__body input[type="text"]:focus,
.affinite-popup-alert-stock__body input[type="email"]:focus {
	outline: none;
	border-color: #00536C;
}

/* GDPR Text */
.affinite-gdpr-text {
	padding: 12px 20px;
	border-top: 1px solid #e1e3e4;
	font-size: 12px;
	color: #666;
}

/* Popup Footer */
.affinite-popup-alert-stock footer {
	padding: 12px 20px;
	border-top: 1px solid #e1e3e4;
	text-align: center;
}

.affinite-popup-alert-submit,
.affinite-popup-response-close {
	display: grid;
	justify-self: center;
	cursor: pointer;
	margin: 0 auto;
	padding: 20px 40px;
	border: 1px solid #00536C;
	border-radius: 100px;
	background-color: #fff;
	color: #00536C;
	font-size: 14px;
	font-weight: 700;
	line-height: 14px;
	letter-spacing: 1px;
	text-transform: uppercase;
	width: fit-content;
	transition: all 0.3s;
	text-decoration: none;
}

.affinite-popup-alert-submit:hover,
.affinite-popup-response-close:hover {
	background-color: #00779A;
	color: #fff;
	opacity: 1;
}

/* Close Button */
.affinite-popup-alert-close {
	line-height: 1;
	font-size: 2em;
	position: absolute;
	top: 10px;
	right: 15px;
	text-decoration: none;
	color: #4F5A5A;
	font-weight: 700;
	opacity: 1;
	transition: opacity 0.3s;
}

.affinite-popup-alert-close:hover {
	opacity: 0.7;
}

/* Overlay */
.affinite-popup-alert-stock__overlay {
	position: absolute;
	display: none;
	left: 0;
	top: 0;
	background: rgba(255, 255, 255, 0.5);
	width: 100%;
	height: 100%;
	align-items: center;
	justify-content: center;
	text-align: center;
	z-index: 10;
}

.affinite-popup-alert-stock__overlay[style*="display: flex"] {
	display: flex !important;
}

.affinite-popup-alert-stock__loader {
	width: 200px;
	height: 200px;
}

/* Response Messages */
.affinite-popup-alert-stock__response,
.affinite-popup-alert-stock__email-error {
	position: absolute;
	display: none;
	left: 0;
	top: 0;
	background: rgba(255, 255, 255, 1);
	width: 100%;
	height: 100%;
	text-align: center;
	border-radius: 4px;
	z-index: 20;
}

.affinite-popup-alert-stock__response[style*="display: block"],
.affinite-popup-alert-stock__email-error[style*="display: block"] {
	display: block !important;
}

.affinite-popup-alert-stock__response-content,
.affinite-popup-alert-stock__email-error-content {
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 20px;
	width: 100%;
	height: 100%;
	padding: 40px !important;
	box-sizing: border-box;
}

.affinite-popup-alert-stock__response h2,
.affinite-popup-alert-stock__email-error h2 {
	margin: 0;
}

.affinite-popup-alert-stock__response h3,
.affinite-popup-alert-stock__email-error h3 {
	margin-bottom: 0;
}

/* Backdrop */
.affinite-popup-alert-stock-backdrop {
	display: none;
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, 0.5);
	z-index: 99999;
}

.affinite-popup-alert-stock-backdrop[style*="display: block"] {
	display: block !important;
}

/* Responsive */
@media only screen and (min-width: 600px) {
	.affinite-popup-alert-stock {
		width: 500px;
	}
}

@media only screen and (max-width: 599px) {
	.affinite-popup-alert-stock {
		width: 80%;
	}
}

