/* ==========================================================================
   IDC Newsletter — Pop-up + Footer block
   Utilise les variables de main.css (--terra, --cream, --coal…)
   ========================================================================== */

/* ---------- Overlay ---------- */
.idc-nl-overlay {
	position: fixed;
	inset: 0;
	z-index: 99999;
	background: rgba(0, 0, 0, 0.55);
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.3s ease, visibility 0.3s ease;
}

.idc-nl-overlay--visible {
	opacity: 1;
	visibility: visible;
}

/* ---------- Pop-up ---------- */
.idc-nl-popup {
	position: relative;
	background: var(--warm, #fff);
	border-radius: 12px;
	padding: 40px 36px 32px;
	max-width: 460px;
	width: 90%;
	text-align: center;
	box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
	transform: translateY(20px);
	transition: transform 0.3s ease;
}

.idc-nl-overlay--visible .idc-nl-popup {
	transform: translateY(0);
}

/* Close button */
.idc-nl-close {
	position: absolute;
	top: 12px;
	right: 12px;
	background: none;
	border: none;
	color: var(--stone, #707070);
	cursor: pointer;
	padding: 4px;
	border-radius: 50%;
	transition: color 0.2s ease, background 0.2s ease;
}

.idc-nl-close:hover {
	color: var(--coal, #111);
	background: var(--cream, #f4f8fb);
}

/* Icon */
.idc-nl-popup__icon {
	color: var(--terra, #4BAEE0);
	margin-bottom: 12px;
}

/* Title */
.idc-nl-popup__title {
	font-size: 22px;
	font-weight: 800;
	color: var(--coal, #111);
	margin: 0 0 8px;
}

/* Text */
.idc-nl-popup__text {
	font-size: 14px;
	color: var(--stone, #707070);
	line-height: 1.5;
	margin: 0 0 20px;
}

.idc-nl-popup__text strong {
	color: var(--terra, #4BAEE0);
	font-size: 16px;
}

/* ---------- Form (shared popup + footer) ---------- */
.idc-nl-form {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

input[type="email"].idc-nl-input,
.idc-nl-input {
	width: 100%;
	padding: 12px 20px;
	border: 2px solid var(--sand, #CBE5F4) !important;
	border-radius: 50px !important;
	font-size: 14px;
	color: var(--coal, #111);
	background: var(--warm, #fff) !important;
	box-shadow: none !important;
	transition: border-color 0.2s ease;
	outline: none;
}

input[type="email"].idc-nl-input:focus,
.idc-nl-input:focus {
	border-color: var(--terra, #4BAEE0) !important;
}

.idc-nl-input::placeholder {
	color: var(--stone, #707070);
}

.idc-nl-submit {
	width: 100%;
	padding: 12px 28px;
	background: var(--terra, #4BAEE0);
	color: var(--warm, #fff);
	border: none;
	border-radius: 50px;
	font-size: 15px;
	font-weight: 700;
	cursor: pointer;
	transition: background 0.2s ease;
}

.idc-nl-submit:hover {
	background: var(--terra-dk, #2E96CC);
}

.idc-nl-submit:disabled {
	opacity: 0.6;
	cursor: not-allowed;
}

/* Message retour */
.idc-nl-msg {
	margin-top: 12px;
	padding: 10px 14px;
	border-radius: 6px;
	font-size: 13px;
	line-height: 1.4;
}

.idc-nl-msg--success {
	background: #eafaf1;
	color: #27ae60;
	border: 1px solid #a3d9a5;
}

.idc-nl-msg--error {
	background: #fdf2f2;
	color: #d63031;
	border: 1px solid #f5c6cb;
}

/* Legal */
.idc-nl-legal {
	font-size: 11px;
	color: var(--stone, #707070);
	margin-top: 12px;
	line-height: 1.4;
}

/* ---------- Footer newsletter form (inside .idc-footer__newsletter band) ---------- */

/* Inline layout */
.idc-footer__newsletter .idc-nl-form--inline {
	flex: 1 1 360px;
	flex-direction: row;
	max-width: 520px;
	gap: 8px;
}

/* Input — match existing footer style (white, rounded) */
.idc-footer__newsletter .idc-nl-input {
	flex: 1 1 auto;
	min-width: 0;
	height: 48px;
	padding: 0 20px;
	border: none;
	border-radius: 50px;
	font-family: "Nunito Sans", sans-serif;
	font-size: 15px;
	background: var(--warm, #fff);
	color: var(--coal, #111);
}

.idc-footer__newsletter .idc-nl-input::placeholder {
	color: var(--stone, #707070);
}

.idc-footer__newsletter .idc-nl-input:focus {
	outline: 2px solid var(--warm, #fff);
	outline-offset: 2px;
}

/* Button — dark, rounded, match existing footer style */
.idc-footer__newsletter .idc-nl-submit {
	width: auto;
	background: var(--brown, #1A1A1A);
	border-radius: 50px;
	padding: 14px 28px;
	font-family: "Nunito", sans-serif;
	font-weight: 800;
	font-size: 14px;
	white-space: nowrap;
}

.idc-footer__newsletter .idc-nl-submit:hover {
	background: #000;
}

/* Msg feedback in footer band */
#idc-nl-msg-footer {
	width: 100%;
	margin: 0;
	padding: 0;
	border-radius: 50px;
	text-align: center;
}

#idc-nl-msg-footer[style*="display:none"],
#idc-nl-msg-footer[style*="display: none"] {
	margin: 0 !important;
	padding: 0 !important;
	height: 0 !important;
	overflow: hidden !important;
}

#idc-nl-msg-footer.idc-nl-msg--success,
#idc-nl-msg-footer.idc-nl-msg--error {
	margin-top: 8px;
	padding: 10px 14px;
}

#idc-nl-msg-footer.idc-nl-msg--success {
	background: rgba(255, 255, 255, 0.15);
	color: #fff;
	border: 1px solid rgba(255, 255, 255, 0.3);
}

#idc-nl-msg-footer.idc-nl-msg--error {
	background: rgba(255, 255, 255, 0.1);
	color: #ffe0e0;
	border: 1px solid rgba(255, 200, 200, 0.3);
}

/* ---------- Responsive ---------- */
@media (max-width: 600px) {
	.idc-nl-popup {
		padding: 32px 20px 24px;
	}

	.idc-nl-popup__title {
		font-size: 18px;
	}

	.idc-footer__newsletter .idc-nl-form--inline {
		flex-direction: column;
		width: 100%;
		max-width: none;
		gap: 10px;
	}

	.idc-footer__newsletter .idc-nl-input {
		width: 100% !important;
		height: 48px !important;
		min-height: 48px !important;
		max-height: 48px !important;
		flex: 0 0 auto !important;
		font-size: 16px;
	}

	.idc-footer__newsletter .idc-nl-submit {
		width: 100%;
		height: 48px;
		flex: 0 0 auto;
	}
}
