/* Interest registration form — modal + inline. */

.ajtha-interest-modal {
	position: fixed;
	inset: 0;
	z-index: 100010; /* above the unit details modal (100000). */
	display: none;
	align-items: center;
	justify-content: center;
	padding: 20px;
}

.ajtha-interest-modal.is-open {
	display: flex;
}

.ajtha-interest-modal__overlay {
	position: absolute;
	inset: 0;
	background: rgba(15, 23, 42, 0.6);
	backdrop-filter: blur(2px);
}

.ajtha-interest-modal__dialog {
	position: relative;
	background: #fff;
	border-radius: 16px;
	width: 100%;
	max-width: 480px;
	max-height: 90vh;
	overflow-y: auto;
	overflow-x: hidden;
	padding: 28px 26px 24px;
	box-shadow: 0 24px 60px rgba(0, 0, 0, 0.25);
	direction: rtl;
	text-align: right;
	/* Follow the site's Elementor global typography, not the browser default. */
	font-family: var(--e-global-typography-text-font-family, inherit);
}

/* Square close button pinned to the top-left corner, matching the unit modal. */
.ajtha-interest-modal__close,
.ajtha-interest-modal__close:focus {
	position: absolute;
	left: 14px;
	right: auto;
	top: 14px;
	width: 34px;
	height: 34px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: #f1f5f9;
	border: 0;
	border-radius: 10px;
	font-size: 22px;
	line-height: 1;
	cursor: pointer;
	color: #64483a;
	padding: 0;
	box-shadow: none;
	transition: background 0.15s ease, color 0.15s ease;
}

.ajtha-interest-modal__close:hover,
.ajtha-interest-modal__close:focus-visible {
	background: #64483a;
	color: #fff;
	outline: none;
}

body.ajtha-interest-lock {
	overflow: hidden;
}

.ajtha-interest-form {
	position: relative;
	max-width: 100%;
}

.ajtha-interest-form__title {
	margin: 0 0 6px;
	font-family: var(--e-global-typography-primary-font-family, inherit);
	font-size: 20px;
	font-weight: 700;
	color: #0f172a;
	padding-inline-end: 44px;
}

.ajtha-interest-form__context {
	margin: 0 0 16px;
	font-size: 13px;
	color: #64748b;
	min-height: 1em;
}

.ajtha-interest-field {
	display: block;
	margin-bottom: 14px;
}

.ajtha-interest-field > span {
	display: block;
	margin-bottom: 6px;
	font-size: 13px;
	font-weight: 600;
	color: #334155;
}

.ajtha-interest-field > span b {
	color: #dc2626;
}

.ajtha-interest-field input,
.ajtha-interest-field textarea {
	width: 100%;
	max-width: 100%;
	box-sizing: border-box;
	border: 1px solid #cbd5e1;
	border-radius: 10px;
	padding: 11px 13px;
	font: inherit;
	font-size: 15px;
	color: #0f172a;
	background: #fff;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.ajtha-interest-field input:focus,
.ajtha-interest-field textarea:focus {
	outline: none;
	border-color: #64483a;
	box-shadow: 0 0 0 3px rgba(100, 72, 58, 0.15);
}

.ajtha-interest-field textarea {
	resize: vertical;
}

/* The subject is derived from the unit/project — shown for confidence, not editing. */
.ajtha-interest-field input[readonly] {
	background: #f8fafc;
	color: #475569;
	cursor: default;
}

.ajtha-interest-field input[readonly]:focus {
	border-color: #cbd5e1;
	box-shadow: none;
}

/*
 * Visually-hidden honeypot. Uses the clip() technique rather than a large
 * negative offset, which pushed the page into horizontal overflow (scrollbar).
 */
.ajtha-interest-hp {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	clip-path: inset(50%);
	white-space: nowrap;
	border: 0;
}

.ajtha-interest-submit {
	width: 100%;
	border: 0;
	border-radius: 10px;
	background: #64483a;
	color: #fff;
	font: inherit;
	font-size: 15px;
	font-weight: 700;
	padding: 13px 18px;
	cursor: pointer;
	transition: background 0.15s ease, opacity 0.15s ease;
}

.ajtha-interest-submit:hover {
	background: #4d3629;
}

.ajtha-interest-submit:disabled {
	opacity: 0.6;
	cursor: default;
}

.ajtha-interest-feedback {
	margin: 12px 0 0;
	font-size: 14px;
	min-height: 1em;
}

.ajtha-interest-feedback.is-pending {
	color: #64748b;
}

.ajtha-interest-feedback.is-success {
	color: #16a34a;
	font-weight: 600;
}

.ajtha-interest-feedback.is-error {
	color: #dc2626;
	font-weight: 600;
}

.ajtha-interest-inline .ajtha-interest-form {
	direction: rtl;
	text-align: right;
	max-width: 480px;
	background: #fff;
	border: 1px solid #e2e8f0;
	border-radius: 16px;
	padding: 24px;
}

/* Trigger produced by [ajtha_interest_button] — plain enough to restyle. */
.ajtha-interest-trigger {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	border: 0;
	border-radius: 10px;
	background: #64483a;
	color: #fff;
	font: inherit;
	font-weight: 700;
	padding: 12px 24px;
	cursor: pointer;
}

.ajtha-interest-trigger:hover {
	background: #4d3629;
	color: #fff;
}
