/* InfoSec Lead Capture: popup, sticky bar, slide-in. */
:root {
	--islc-place-accent: #0ea5a4;
	--islc-place-bar-bg: #0b1220;
	--islc-place-bar-text: #e2e8f0;
	--islc-bar-h: 52px;
}

.islc-modal[hidden],
.islc-bar[hidden],
.islc-slidein[hidden] { display: none !important; }

.islc-close {
	position: absolute;
	top: 8px;
	right: 8px;
	width: 36px;
	height: 36px;
	padding: 0;
	font-size: 26px;
	line-height: 1;
	color: #64748b;
	background: transparent;
	border: 0;
	border-radius: 50%;
	cursor: pointer;
	z-index: 2;
}
.islc-close:hover,
.islc-close:focus-visible { background: rgba(100, 116, 139, 0.15); color: #0f172a; }

/* Popup */
html.islc-modal-open { overflow: hidden; }
.islc-modal {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
}
.islc-modal__overlay {
	position: absolute;
	inset: 0;
	background: rgba(2, 6, 23, 0.7);
	backdrop-filter: blur(3px);
	animation: islc-fade 0.2s ease;
}
.islc-modal__box {
	position: relative;
	width: 100%;
	max-width: 520px;
	max-height: calc(100vh - 32px);
	overflow-y: auto;
	border-radius: 16px;
	animation: islc-rise 0.25s ease;
}
.islc-modal__box .islc { margin: 0; max-width: none; box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35); }

/* Sticky top bar */
html.islc-has-bar body { padding-top: var(--islc-bar-h); }
html.islc-has-bar body.admin-bar .islc-bar { top: 32px; }
.islc-bar {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	z-index: 99999;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 16px;
	min-height: 52px;
	padding: 8px 52px 8px 16px;
	color: var(--islc-place-bar-text);
	background: var(--islc-place-bar-bg);
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
	font-size: 15px;
	line-height: 1.35;
}
.islc-bar__text { margin: 0; }
.islc-bar__button {
	flex: none;
	padding: 8px 16px;
	font: inherit;
	font-weight: 700;
	color: #fff;
	background: var(--islc-place-accent);
	border: 0;
	border-radius: 8px;
	cursor: pointer;
}
.islc-bar__button:hover,
.islc-bar__button:focus-visible { filter: brightness(0.9); }
.islc-bar .islc-close { top: 50%; transform: translateY(-50%); color: #94a3b8; }
.islc-bar .islc-close:hover { color: #fff; background: rgba(255, 255, 255, 0.1); }

/* Slide-in */
.islc-slidein {
	position: fixed;
	right: 20px;
	bottom: 20px;
	z-index: 99998;
	width: 360px;
	max-width: calc(100vw - 40px);
	max-height: calc(100vh - 40px);
	overflow-y: auto;
	padding: 20px 20px 16px;
	background: #fff;
	border: 1px solid #e2e8f0;
	border-radius: 14px;
	box-shadow: 0 18px 48px rgba(15, 23, 42, 0.22);
	animation: islc-slide 0.3s ease;
}
.islc-slidein .islc { max-width: none; font-size: 15px; }
.islc-slidein .islc .islc__title { font-size: 1.1rem; padding-right: 28px; }
.islc-slidein .islc__field label { font-size: 0.85rem; }
.islc-slidein .islc__consent { margin: 10px 0; font-size: 0.78rem; }

@media (max-width: 782px) {
	html.islc-has-bar body.admin-bar .islc-bar { top: 46px; }
	.islc-bar { font-size: 14px; gap: 10px; padding: 8px 44px 8px 12px; justify-content: space-between; }
	.islc-bar__button { padding: 7px 12px; }

	/* Slide-in becomes a compact bottom sheet that leaves most of the page visible. */
	.islc-slidein {
		left: 0;
		right: 0;
		bottom: 0;
		width: auto;
		max-width: none;
		max-height: 70vh;
		border-radius: 16px 16px 0 0;
		padding: 18px 16px 12px;
	}
	.islc-modal { align-items: flex-end; padding: 0; }
	.islc-modal__box { max-width: none; max-height: 90vh; border-radius: 16px 16px 0 0; }
	.islc-modal__box .islc { border-radius: 16px 16px 0 0; }
}

@keyframes islc-fade { from { opacity: 0; } }
@keyframes islc-rise { from { opacity: 0; transform: translateY(16px); } }
@keyframes islc-slide { from { opacity: 0; transform: translateY(24px); } }
@media (prefers-reduced-motion: reduce) {
	.islc-modal__overlay,
	.islc-modal__box,
	.islc-slidein { animation: none; }
}

/* Popup with a cover image needs room for two columns. */
.islc-modal--wide .islc-modal__box { max-width: 860px; }
@media (max-width: 782px) {
	.islc-modal--wide .islc .islc__image { max-width: 140px; }
}
