/**
 * Feedback / Report an Issue modal styles
 *
 * @package NEC_Archives
 */

.nec-feedback-modal.modal {
	display: none;
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0, 0, 0, 0.5);
	z-index: 10000;
	overflow-y: auto;
	padding: 2rem 1rem;
}

.nec-feedback-modal .modal-content {
	position: relative;
	background: #fff;
	border-radius: 8px;
	max-width: 560px;
	margin: 2rem auto;
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
	border-top: 3px solid #334196;
}

.nec-feedback-processing {
	display: none;
	position: absolute;
	inset: 0;
	z-index: 5;
	background: rgba(255, 255, 255, 0.92);
	border-radius: 8px;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 1rem;
	padding: 2rem;
	text-align: center;
}

.nec-feedback-processing.is-active {
	display: flex;
}

.nec-feedback-processing p {
	margin: 0;
	font-size: 1rem;
	font-weight: 600;
	color: #334196;
}

.nec-feedback-spinner {
	width: 44px;
	height: 44px;
	border: 3px solid #e4e7f2;
	border-top-color: #334196;
	border-radius: 50%;
	animation: nec-feedback-spin 0.75s linear infinite;
}

@keyframes nec-feedback-spin {
	to {
		transform: rotate(360deg);
	}
}

.nec-feedback-modal.is-processing .modal-close,
.nec-feedback-modal.is-processing .nec-feedback-close {
	pointer-events: none;
	opacity: 0.45;
}

.nec-feedback-modal .modal-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 1.25rem 1.75rem;
	border-bottom: 1px solid #e9ecef;
}

.nec-feedback-modal .modal-header h2 {
	margin: 0;
	font-size: 1.35rem;
	color: #334196;
	font-weight: 600;
}

.nec-feedback-modal .modal-close {
	background: none;
	border: none;
	font-size: 1.75rem;
	color: #999;
	cursor: pointer;
	line-height: 1;
	padding: 0;
	width: 32px;
	height: 32px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 4px;
	transition: all 0.2s;
}

.nec-feedback-modal .modal-close:hover {
	background: #f0f2f8;
	color: #334196;
}

.nec-feedback-modal .modal-body {
	padding: 1.5rem 1.75rem 1.75rem;
}

.nec-feedback-intro {
	margin: 0 0 1.25rem;
	color: #555;
	font-size: 0.95rem;
	line-height: 1.5;
}

.nec-feedback-modal .form-group {
	margin-bottom: 1.1rem;
}

.nec-feedback-modal .form-group label {
	display: block;
	margin-bottom: 0.4rem;
	font-size: 0.9rem;
	font-weight: 600;
	color: #2c3e50;
}

.nec-feedback-modal .form-group .required {
	color: #c0392b;
}

.nec-feedback-modal .form-group .optional {
	font-weight: 400;
	color: #888;
	font-size: 0.85em;
}

.nec-feedback-modal .form-control {
	width: 100%;
	padding: 0.65rem 0.85rem;
	border: 1px solid #d3d3d3;
	border-radius: 4px;
	font-size: 0.95rem;
	line-height: 1.4;
	color: #141414;
	background: #fff;
	box-sizing: border-box;
	transition: border-color 0.2s, box-shadow 0.2s;
}

.nec-feedback-modal .form-control:focus {
	outline: none;
	border-color: #334196;
	box-shadow: 0 0 0 2px rgba(51, 65, 150, 0.15);
}

.nec-feedback-modal textarea.form-control {
	resize: vertical;
	min-height: 120px;
}

/* Honeypot — visually hidden but present for bots */
.nec-feedback-hp {
	position: absolute;
	left: -9999px;
	top: auto;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.nec-feedback-modal .modal-footer {
	display: flex;
	justify-content: flex-end;
	gap: 0.75rem;
	margin-top: 1.5rem;
	padding-top: 0;
}

.nec-feedback-modal .btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0.65rem 1.25rem;
	border-radius: 4px;
	font-size: 0.95rem;
	font-weight: 600;
	cursor: pointer;
	border: none;
	text-decoration: none;
	transition: background 0.2s, color 0.2s, opacity 0.2s;
}

.nec-feedback-modal .btn-primary {
	background: #334196;
	color: #fff;
}

.nec-feedback-modal .btn-primary:hover {
	background: #2a3578;
}

.nec-feedback-modal .btn-primary:disabled {
	opacity: 0.65;
	cursor: not-allowed;
}

.nec-feedback-modal .btn-secondary {
	background: #f0f2f8;
	color: #334196;
}

.nec-feedback-modal .btn-secondary:hover {
	background: #e4e7f2;
}

.nec-feedback-alert {
	padding: 0.75rem 1rem;
	border-radius: 4px;
	font-size: 0.9rem;
	margin-bottom: 1rem;
}

.nec-feedback-alert.is-error {
	background: #f8d7da;
	color: #721c24;
	border: 1px solid #f5c6cb;
}

.nec-feedback-alert.is-success {
	background: #d4edda;
	color: #155724;
	border: 1px solid #c3e6cb;
}

.nec-feedback-success {
	text-align: center;
	padding: 1.5rem 0 0.5rem;
}

.nec-feedback-success p {
	font-size: 1.05rem;
	color: #2c3e50;
	margin: 0 0 1.5rem;
}

/* Invisible reCAPTCHA slot — keep in layout flow so Google can attach the badge */
.nec-feedback-recaptcha {
	min-height: 0;
	line-height: 0;
	overflow: visible;
}

/* Invisible reCAPTCHA badge positioning nudge */
.grecaptcha-badge {
	z-index: 10001 !important;
	visibility: visible !important;
	opacity: 1 !important;
}

@media (max-width: 600px) {
	.nec-feedback-modal {
		padding: 1rem 0.5rem;
	}

	.nec-feedback-modal .modal-header,
	.nec-feedback-modal .modal-body {
		padding: 1rem 1.15rem;
	}

	.nec-feedback-modal .modal-footer {
		flex-direction: column-reverse;
	}

	.nec-feedback-modal .btn {
		width: 100%;
	}
}
