/* Cloudformatie Megamenu — alle stijlen scoped op .cfmm-wrap */

.cfmm-wrap,
.cfmm-wrap * {
	box-sizing: border-box;
}

.cfmm-wrap {
	font-family: 'Source Sans 3', system-ui, -apple-system, sans-serif;
	position: relative;
	z-index: 300;
}

/* ---------- bovenbalk ---------- */

.cfmm-wrap .cfmm-topbar {
	background: var(--cfmm-deep, #0C2E42);
	font-size: 13.5px;
	line-height: 1.4;
}

.cfmm-wrap .cfmm-topbar-inner {
	max-width: 1240px;
	margin: 0 auto;
	padding: 9px 24px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
}

.cfmm-wrap .cfmm-topbar-links,
.cfmm-wrap .cfmm-topbar-rechts {
	display: flex;
	align-items: center;
	gap: 14px;
	flex-wrap: wrap;
}

.cfmm-wrap .cfmm-tagline {
	color: var(--cfmm-soft, #BEDCEA);
}

.cfmm-wrap .cfmm-scheiding {
	color: var(--cfmm-soft, #BEDCEA);
	opacity: 0.35;
}

.cfmm-wrap .cfmm-topbar a {
	color: var(--cfmm-soft, #BEDCEA);
	text-decoration: none;
	font-weight: 600;
	transition: color 0.15s ease;
}

.cfmm-wrap .cfmm-topbar a:hover,
.cfmm-wrap .cfmm-topbar a:focus {
	color: #FFFFFF;
}

/* ---------- header ---------- */

.cfmm-wrap .cfmm-header {
	background: rgba(255, 255, 255, 0.94);
	backdrop-filter: blur(12px);
	-webkit-backdrop-filter: blur(12px);
	border-bottom: 1px solid var(--cfmm-border, #DCE7ED);
	position: relative;
}

.cfmm-wrap .cfmm-header.cfmm-sticky {
	position: sticky;
	top: 0;
	z-index: 320;
}

.admin-bar .cfmm-wrap .cfmm-header.cfmm-sticky {
	top: 32px;
}

.cfmm-wrap .cfmm-header-inner {
	max-width: 1240px;
	margin: 0 auto;
	padding: 14px 24px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
}

.cfmm-wrap .cfmm-logo {
	flex: none;
	display: flex;
	align-items: center;
	text-decoration: none;
}

.cfmm-wrap .cfmm-logo img {
	height: 42px;
	width: auto;
	display: block;
}

.cfmm-wrap .cfmm-logo-tekst {
	font-family: 'Manrope', sans-serif;
	font-weight: 800;
	font-size: 20px;
	color: var(--cfmm-ink, #0C1F2C);
}

/* ---------- navigatie ---------- */

.cfmm-wrap .cfmm-nav > ul {
	display: flex;
	align-items: center;
	gap: 2px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.cfmm-wrap .cfmm-nav-item {
	list-style: none;
	margin: 0;
	padding: 0;
	position: static;
}

.cfmm-wrap .cfmm-nav-link {
	display: flex;
	align-items: center;
	gap: 7px;
	padding: 9px 12px;
	border-radius: 8px;
	font-family: 'Manrope', sans-serif;
	font-weight: 600;
	font-size: 14.5px;
	line-height: 1.2;
	color: var(--cfmm-ink, #0C1F2C);
	text-decoration: none;
	white-space: nowrap;
	transition: background 0.15s ease, color 0.15s ease;
}

.cfmm-wrap .cfmm-nav-item:hover > .cfmm-nav-link,
.cfmm-wrap .cfmm-nav-link:focus-visible,
.cfmm-wrap .cfmm-nav-item.cfmm-open > .cfmm-nav-link {
	background: var(--cfmm-light, #EAF4F9);
	color: var(--cfmm-mid, #075E86);
}

.cfmm-wrap .cfmm-pijl {
	width: 6px;
	height: 6px;
	border-right: 2px solid #9BB0BC;
	border-bottom: 2px solid #9BB0BC;
	transform: rotate(45deg) translate(-2px, -2px);
	transition: border-color 0.15s ease;
}

.cfmm-wrap .cfmm-nav-item:hover > .cfmm-nav-link .cfmm-pijl,
.cfmm-wrap .cfmm-nav-item.cfmm-open > .cfmm-nav-link .cfmm-pijl {
	border-color: var(--cfmm-mid, #075E86);
}

/* ---------- paneel ---------- */

.cfmm-wrap .cfmm-panel {
	position: absolute;
	top: 100%;
	left: 0;
	right: 0;
	padding-top: 0;
	opacity: 0;
	visibility: hidden;
	transform: translateY(-6px);
	transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s;
	z-index: 330;
}

.cfmm-wrap .cfmm-nav-item:hover > .cfmm-panel,
.cfmm-wrap .cfmm-nav-item.cfmm-open > .cfmm-panel {
	opacity: 1;
	visibility: visible;
	transform: none;
}

.cfmm-wrap .cfmm-panel-inner {
	max-width: 1240px;
	margin: 0 auto;
	padding: 22px 24px 20px;
	background: #FFFFFF;
	border: 1px solid var(--cfmm-border, #DCE7ED);
	border-top: 0;
	border-radius: 0 0 18px 18px;
	box-shadow: 0 24px 50px -26px rgba(7, 45, 66, 0.3);
}

/* volle breedte: paneel spant het venster, inhoud blijft op 1240 */
.cfmm-wrap.cfmm-vol .cfmm-panel {
	left: 50%;
	right: auto;
	width: 100vw;
	margin-left: -50vw;
}

.cfmm-wrap.cfmm-vol .cfmm-panel-inner {
	border-left: 0;
	border-right: 0;
	border-radius: 0;
	max-width: none;
	padding-left: max(24px, calc(50vw - 596px));
	padding-right: max(24px, calc(50vw - 596px));
}

/* het grid — kolommen kunnen niet overlappen */
.cfmm-wrap .cfmm-grid {
	display: grid;
	grid-template-columns: repeat(var(--cfmm-cols, 3), minmax(0, 1fr));
	grid-auto-flow: column;
	grid-template-rows: repeat(var(--cfmm-rows, 4), auto);
	gap: 2px 40px;
	align-items: start;
}

.cfmm-wrap .cfmm-item {
	display: block;
	padding: 10px 12px;
	border-radius: 9px;
	text-decoration: none;
	min-width: 0;
	transition: background 0.13s ease;
}

.cfmm-wrap .cfmm-item:hover,
.cfmm-wrap .cfmm-item:focus-visible {
	background: var(--cfmm-light, #EAF4F9);
}

.cfmm-wrap .cfmm-item-titel {
	display: block;
	font-family: 'Manrope', sans-serif;
	font-weight: 700;
	font-size: 14.5px;
	line-height: 1.3;
	color: var(--cfmm-ink, #0C1F2C);
}

.cfmm-wrap .cfmm-item-oms {
	display: block;
	font-size: 13px;
	line-height: 1.45;
	color: var(--cfmm-muted, #5A7182);
	margin-top: 2px;
	overflow-wrap: break-word;
}

.cfmm-wrap .cfmm-cta {
	margin-top: 14px;
	padding: 14px 16px;
	background: var(--cfmm-light, #EAF4F9);
	border-radius: 12px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	font-size: 14.5px;
	color: var(--cfmm-body, #425A69);
	flex-wrap: wrap;
}

.cfmm-wrap .cfmm-cta a {
	font-family: 'Manrope', sans-serif;
	font-weight: 700;
	font-size: 14px;
	color: var(--cfmm-mid, #075E86);
	text-decoration: none;
	border-bottom: 1.5px solid var(--cfmm-orange, #F5821F);
	padding-bottom: 2px;
	white-space: nowrap;
}

.cfmm-wrap .cfmm-cta a:hover {
	color: var(--cfmm-ink, #0C1F2C);
}

/* ---------- knop rechts ---------- */

.cfmm-wrap .cfmm-knop {
	flex: none;
	font-family: 'Manrope', sans-serif;
	font-weight: 700;
	font-size: 14.5px;
	line-height: 1.2;
	color: #FFFFFF;
	background: var(--cfmm-blue, #0A87BE);
	padding: 12px 20px;
	border-radius: 999px;
	text-decoration: none;
	box-shadow: 0 8px 20px -8px rgba(10, 135, 190, 0.7);
	transition: background 0.15s ease;
	white-space: nowrap;
}

.cfmm-wrap .cfmm-knop:hover,
.cfmm-wrap .cfmm-knop:focus {
	background: var(--cfmm-mid, #075E86);
	color: #FFFFFF;
}

/* ---------- hamburger ---------- */

.cfmm-wrap .cfmm-burger {
	display: none;
	width: 46px;
	height: 46px;
	flex: none;
	border: 1px solid var(--cfmm-border, #DCE7ED);
	border-radius: 12px;
	background: #FFFFFF;
	cursor: pointer;
	padding: 0;
	align-items: center;
	justify-content: center;
	flex-direction: column;
	gap: 5px;
}

.cfmm-wrap .cfmm-burger span {
	display: block;
	width: 20px;
	height: 2px;
	background: var(--cfmm-ink, #0C1F2C);
	border-radius: 2px;
	transition: transform 0.2s ease, opacity 0.2s ease;
}

.cfmm-wrap .cfmm-burger[aria-expanded="true"] span:nth-child(1) {
	transform: translateY(7px) rotate(45deg);
}

.cfmm-wrap .cfmm-burger[aria-expanded="true"] span:nth-child(2) {
	opacity: 0;
}

.cfmm-wrap .cfmm-burger[aria-expanded="true"] span:nth-child(3) {
	transform: translateY(-7px) rotate(-45deg);
}

/* ---------- mobiel menu ---------- */

.cfmm-wrap .cfmm-mobiel {
	display: none;
	background: #FFFFFF;
	border-bottom: 1px solid var(--cfmm-border, #DCE7ED);
	padding: 8px 20px 20px;
}

.cfmm-wrap .cfmm-mobiel[hidden] {
	display: none !important;
}

.cfmm-wrap .cfmm-mobiel-link,
.cfmm-wrap .cfmm-mobiel-knop {
	display: flex;
	align-items: center;
	justify-content: space-between;
	width: 100%;
	min-height: 48px;
	padding: 13px 12px;
	border: 0;
	border-bottom: 1px solid #EFF4F7;
	background: none;
	font-family: 'Manrope', sans-serif;
	font-weight: 700;
	font-size: 16.5px;
	color: var(--cfmm-ink, #0C1F2C);
	text-decoration: none;
	text-align: left;
	cursor: pointer;
}

.cfmm-wrap .cfmm-mobiel-teken {
	width: 10px;
	height: 10px;
	border-right: 2px solid var(--cfmm-blue, #0A87BE);
	border-bottom: 2px solid var(--cfmm-blue, #0A87BE);
	transform: rotate(45deg) translate(-2px, -2px);
	transition: transform 0.2s ease;
}

.cfmm-wrap .cfmm-mobiel-knop[aria-expanded="true"] .cfmm-mobiel-teken {
	transform: rotate(-135deg) translate(-3px, -3px);
}

.cfmm-wrap .cfmm-mobiel-sub {
	padding: 4px 0 10px;
}

.cfmm-wrap .cfmm-mobiel-sub[hidden] {
	display: none;
}

.cfmm-wrap .cfmm-mobiel-sub a {
	display: block;
	min-height: 44px;
	padding: 12px 12px 12px 24px;
	font-size: 15.5px;
	line-height: 1.4;
	color: var(--cfmm-body, #425A69);
	text-decoration: none;
}

.cfmm-wrap .cfmm-mobiel-sub a:active {
	background: var(--cfmm-light, #EAF4F9);
}

.cfmm-wrap .cfmm-mobiel-portaal {
	display: block;
	margin-top: 18px;
	padding: 15px;
	text-align: center;
	background: var(--cfmm-blue, #0A87BE);
	color: #FFFFFF;
	border-radius: 999px;
	font-family: 'Manrope', sans-serif;
	font-weight: 700;
	font-size: 16px;
	text-decoration: none;
}

/* alleen het menu: geen eigen achtergrond, past in een bestaande header */
.cfmm-wrap.cfmm-alleen-menu .cfmm-header {
	background: none;
	backdrop-filter: none;
	-webkit-backdrop-filter: none;
	border-bottom: 0;
}

.cfmm-wrap.cfmm-alleen-menu .cfmm-header-inner {
	padding: 0;
	max-width: none;
	justify-content: flex-start;
}

.cfmm-wrap.cfmm-alleen-menu .cfmm-mobiel {
	border-bottom: 0;
	padding: 8px 0 12px;
}

/* ---------- responsive ---------- */

@media (max-width: 1180px) {
	.cfmm-wrap .cfmm-nav-link {
		font-size: 13.5px;
		padding: 9px 9px;
	}
	.cfmm-wrap .cfmm-grid {
		gap: 2px 28px;
	}
}

@media (max-width: 1024px) {
	.cfmm-wrap .cfmm-nav,
	.cfmm-wrap .cfmm-knop {
		display: none;
	}
	.cfmm-wrap .cfmm-burger {
		display: flex;
	}
	.cfmm-wrap .cfmm-mobiel {
		display: block;
	}
	.cfmm-wrap .cfmm-header-inner {
		padding: 10px 20px;
	}
	.cfmm-wrap .cfmm-logo img {
		height: 34px;
	}
	.cfmm-wrap .cfmm-topbar-inner {
		padding: 7px 20px;
		justify-content: center;
		gap: 12px;
	}
	.cfmm-wrap .cfmm-topbar-links {
		display: none;
	}
	.cfmm-wrap .cfmm-topbar-rechts {
		gap: 10px;
		flex-wrap: nowrap;
		white-space: nowrap;
		font-size: 12.5px;
	}
}

@media (max-width: 420px) {
	.cfmm-wrap .cfmm-topbar-rechts .cfmm-scheiding,
	.cfmm-wrap .cfmm-topbar-rechts .cfmm-email {
		display: none;
	}
}

@media (prefers-reduced-motion: reduce) {
	.cfmm-wrap * {
		transition: none !important;
	}
}
