/**
 * Popup Login/Register System Styles
 * Modern responsive popup design
 */

/* Popup Overlay */
.mt-popup-wrap {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	z-index: 99999;
	display: none;
	align-items: center;
	justify-content: center;
	padding: 20px;
	box-sizing: border-box;
	font-family: "Open Sans", sans-serif !important;

	/* display: flex !important; */
}

.mt-popup-wrap.active {
	display: flex;
}

.popup-overlay {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, 0);
	backdrop-filter: blur(2px);
}

/* Popup Block */
.popup-block {
	position: relative;
	background: #fff;
	border-radius: 4px;
	box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
	width: 100%;
	max-width: 458px;
	max-height: 90vh;
	overflow-y: auto;
	transform: scale(0.9);
	opacity: 0;
	transition: all 0.3s ease;
	display: none;
	overflow-x: hidden;

	/* display: block !important;
	transform: scale(1) !important;
	opacity: 1 !important; */
}

.popup-block.active {
	display: block;
	transform: scale(1);
	opacity: 1;
}

/* Popup Header */
.popup-header {
	position: relative;
	padding: 33px 24px 15px;
}

.popup-title {
	font-size: 24px;
	font-weight: 600;
	color: #222222;
	margin: 0;
}

.required-mark {
	position: absolute;
	bottom: 10px;
	right: 24px;
	font-size: 14px;
	color: #222222;
	font-weight: 400;
}

.popup-close {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	right: -1px;
	width: 28px;
	height: 28px;
	background: transparent;
	border: none;
	cursor: pointer;
	font-size: 38px;
	color: #222222;
	transition: all 0.3s ease;
	outline: none;
	display: flex;
	align-items: center;
	justify-content: center;
	font-weight: 400;
}

.popup-close:hover {
	opacity: 0.8;
}

/* Popup Content */
.popup-content {
	padding: 25px 24px 32px 24px;
}

/* Auth Switch */
.auth-switch {
	text-align: left;
	margin-bottom: 25px;
	font-size: 14px;
	color: #222222;
	font-size: 16px;
	position: relative;
}

@media (max-width: 425px) {
	.auth-switch {
		padding-right: 30px;
	}
}

.auth-switch a {
	text-decoration: underline;
	font-weight: 500;
	font-size: 16px;
	font-weight: 700;
	color: #222222;
	transition: all 0.3s ease;
}

.auth-switch a:hover {
	opacity: 0.8;
}

.auth-switch a:hover {
	text-decoration: none;
}

/* Form Groups */
.popup-content .popup-form .form-group {
	margin-bottom: 30px;
}

.popup-content .popup-form .form-group:nth-of-type(2) {
	margin-bottom: 35px;
}

.popup-content .popup-form .form-group.last-child {
	margin-bottom: 0;
}


.form-group label {
	display: block;
	margin-bottom: 8px;
	font-weight: 400;
	color: #222222;
	font-size: 16px;
}

.popup-content .popup-form .form-group .form-control {
	height: 36px;
	width: 100%;
	padding: 10px 8px;
	border: 1px solid #CED4DA;
	border-radius: 4px;
	font-size: 16px;
	transition: all 0.3s ease;
	box-sizing: border-box;
	background-color: #ffffff !important;
	color: #222222;
}

.popup-content .popup-form .form-group .form-control:focus {
	outline: none;
	background-color: #ffffff;
	box-shadow: none;
}

.popup-content .popup-form .form-group .error-message {
	color: #981111;
	margin-top: 8px;
}

.form-control.error {
	border-color: #dc3545;
}

.form-control::placeholder {
	color: #999;
	font-size: 14px;
}

/* Password Wrapper */
.password-wrapper {
	position: relative;
}

.view-pass {
	position: absolute;
	top: 8px;
	right: 10px;
	cursor: pointer;
	width: 20px;
	height: 20px;
	background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 12a3 3 0 11-6 0 3 3 0 016 0z"/><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M2.458 12C3.732 7.943 7.523 5 12 5c4.478 0 8.268 2.943 9.542 7-1.274 4.057-5.064 7-9.542 7-4.477 0-8.268-2.943-9.542-7z"/></svg>');
	background-size: contain;
	background-repeat: no-repeat;
	opacity: 0.5;
	transition: opacity 0.2s ease;
}

.view-pass:hover {
	opacity: 0.8;
}

.view-pass.active {
	background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke="currentColor"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M13.875 18.825A10.05 10.05 0 0112 19c-4.478 0-8.268-2.943-9.543-7a9.97 9.97 0 011.563-3.029m5.858.908a3 3 0 114.243 4.243M9.878 9.878l4.242 4.242M9.878 9.878L3 3m6.878 6.878L21 21"/></svg>');
}

/* Form Options */
.popup-content .popup-form .form-group.form-options {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 35px;
}

.remember-me {
	display: flex;
	align-items: center;
	gap: 8px;
}

.remember-me input[type="checkbox"] {
	margin: 0;
	width: 16px;
	height: 16px;
}

.form-group .checker {
	margin-right: 0 !important;
	display: flex;
	align-items: center;
	top: 0;
}

.form-group .checker .checked {
	background-image: url('/wp-content/uploads/2025/08/checks-black2x.jpg');
}

.form-group .checker span {
	margin-top: 0;
}

.remember-me label {
	margin: 0;
	font-size: 16px;
	color: #222222;
	cursor: pointer;
	font-weight: 400;
}

.forgot-password a {
	color: #545454;
	text-decoration: none;
	font-size: 16px;
}

.forgot-password a:hover {
	text-decoration: underline;
}

/* Checkbox Wrapper */
.checkbox-wrapper {
	display: flex;
	align-items: flex-start;
	gap: 10px;
}

.checkbox-wrapper input[type="checkbox"] {
	margin: 4px 0 0 0;
	flex-shrink: 0;
}

.checkbox-wrapper label {
	margin: 0;
	font-size: 14px;
	line-height: 1.4;
	cursor: pointer;
}

.checkbox-wrapper a {
	color: #36513C;
	text-decoration: none;
}

.checkbox-wrapper a:hover {
	text-decoration: underline;
}

/* Buttons */
.btn {
	display: inline-block;
	font-weight: 500;
	text-align: center;
	white-space: nowrap;
	vertical-align: middle;
	user-select: none;
	border: 1px solid transparent;
	padding: 12px 24px;
	font-size: 14px;
	line-height: 1.5;
	border-radius: 8px;
	transition: all 0.2s ease;
	cursor: pointer;
	text-decoration: none;
	box-sizing: border-box;
}

.btn-primary {
	color: #fff;
	background-color: #36513C;
	border: none;
	font-weight: 400;
	font-size: 16px;
	min-height: 46px;
	border-radius: 4px;
}

.btn-primary:focus {
	background-color: #36513C;
}

	{

	.btn-primary:hover {
		background-color: #3e5537;
		border-color: #3e5537;
	}

	.btn-primary:disabled {
		opacity: 0.6;
		cursor: not-allowed;
	}

	.w-full {
		width: 100%;
	}

	/* Error Messages */
	.error-message {
		color: #dc3545;
		font-size: 12px;
		margin-top: 5px;
		display: none;
	}

	.error-message.visible {
		display: block;
	}

	.error-block {
		background: #f8d7da;
		color: #721c24;
		padding: 10px 15px;
		border-radius: 6px;
		font-size: 14px;
		margin-top: 15px;
		display: none;
	}

	.error-block.visible {
		display: block;
	}

	.success-block {
		background: #d4edda;
		color: #155724;
		padding: 10px 15px;
		border-radius: 6px;
		font-size: 14px;
		margin-top: 15px;
		display: none;
	}

	.success-block.visible {
		display: block;
	}

	/* Loading State */
	.btn.loading {
		position: relative;
		color: transparent;
	}

	.btn.loading::after {
		content: '';
		position: absolute;
		top: 50%;
		left: 50%;
		transform: translate(-50%, -50%);
		width: 16px;
		height: 16px;
		border: 2px solid currentColor;
		border-radius: 50%;
		border-top-color: transparent;
		animation: spin 1s linear infinite;
	}

	@keyframes spin {
		to {
			transform: translate(-50%, -50%) rotate(360deg);
		}
	}

	/* Responsive Design */
	@media (max-width: 768px) {
		.mt-popup-wrap {
			padding: 10px;
		}

		.popup-block {
			max-width: 100%;
			border-radius: 8px;
		}

		.popup-header {
			padding: 20px 20px 15px;
		}

		.popup-content {
			padding: 20px;
		}

		.popup-title {
			font-size: 20px;
		}

		.form-options {
			flex-direction: column;
			align-items: flex-start;
			gap: 15px;
		}
	}

	@media (max-width: 480px) {
		.popup-header {
			padding: 15px 15px 10px;
		}

		.popup-content {
			padding: 15px;
		}

		.form-group {
			margin-bottom: 15px;
		}
	}

	/* High Contrast Mode Support */
	@media (prefers-contrast: high) {
		.popup-block {
			border: 2px solid #000;
		}

		.form-control {
			border-width: 2px;
		}

		.btn-primary {
			border-width: 2px;
		}
	}

	/* Reduced Motion Support */
	@media (prefers-reduced-motion: reduce) {

		.popup-block,
		.popup-close,
		.form-control,
		.btn {
			transition: none;
		}

		.btn.loading::after {
			animation: none;
		}
	}