/* ==========================================================================
   NP INVESTOR — CUSTOM HEADER + MEGA-MENU (Fase 5)
   ========================================================================== */

/* Skjul Astras egen header helt — vi rendrer vores egen. */
#masthead { display: none !important; }

.np-hd {
	position: sticky; top: 0; z-index: 200;
	background: var(--np-navy-700);
	box-shadow: 0 1px 0 rgba(0,0,0,.28);
}
.np-hd__inner {
	max-width: var(--np-container); margin: 0 auto;
	padding: 0 clamp(16px, 4vw, 32px);
	height: var(--np-header-h);
	display: flex; align-items: center; gap: 26px;
}
.np-hd .np-logo { flex: 0 0 auto; color: #fff; }
.np-hd__nav { flex: 1 1 auto; min-width: 0; }
.np-hd__menu { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: 2px; }
.np-hd__item { position: relative; }
.np-hd__link {
	display: inline-flex; align-items: center; gap: 5px;
	padding: 10px 13px; border-radius: 8px;
	color: rgba(255,255,255,.86);
	font-family: var(--np-font-sans); font-weight: 500; font-size: 15px; letter-spacing: -.01em;
	white-space: nowrap;
}
.np-hd__link:hover, .np-hd__item--mega:hover > .np-hd__link { color: #fff; }
.np-hd__chev { font-size: 10px; opacity: .8; transition: transform .16s ease; }
.np-hd__item--mega:hover > .np-hd__link .np-hd__chev { transform: rotate(180deg); }

/* Mega-panel */
.np-mega {
	position: absolute; top: calc(100% + 8px); left: 0;
	background: var(--np-navy-800);
	border: 1px solid rgba(255,255,255,.08); border-radius: 14px;
	box-shadow: var(--np-shadow-lg);
	padding: 26px 28px;
	width: max-content; max-width: 94vw;
	opacity: 0; visibility: hidden; transform: translateY(6px);
	transition: opacity .16s ease, transform .16s ease, visibility .16s ease;
}
.np-hd__item--mega:hover > .np-mega { opacity: 1; visibility: visible; transform: translateY(0); }
.np-mega::before { /* usynlig bro saa hover ikke falder */
	content: ""; position: absolute; top: -10px; left: 0; right: 0; height: 12px;
}
.np-mega__grid { display: flex; flex-wrap: nowrap; align-items: flex-start; }
.np-mega__col { flex: 0 0 auto; min-width: 172px; padding: 0 24px; }
.np-mega__col:first-child { padding-left: 0; }
.np-mega__col + .np-mega__col { border-left: 1px solid rgba(255,255,255,.08); }
.np-mega__title {
	display: block; font-family: var(--np-font-sans);
	font-size: 11.5px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
	color: #2fe0cf; margin-bottom: 12px;
}
.np-mega__col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 1px; }
.np-mega__col a {
	display: block; padding: 7px 10px; margin: 0 -10px; border-radius: 8px;
	color: rgba(255,255,255,.78); font-size: 14px; line-height: 1.35;
	transition: background .12s ease, color .12s ease;
}
.np-mega__col a:hover { background: rgba(255,255,255,.07); color: #fff; }
.np-mega__all { margin-top: 6px; }
.np-mega__all a { color: #2fe0cf; font-weight: 600; }
.np-mega__all a:hover { background: rgba(47,224,207,.12); color: #4ff0e0; }

/* CTA */
.np-hd__cta {
	flex: 0 0 auto; display: inline-flex; align-items: center; gap: 8px;
	background: var(--np-up); color: #fff !important;
	font-family: var(--np-font-sans); font-weight: 600; font-size: 14px;
	padding: 9px 16px; border-radius: 8px; white-space: nowrap;
	transition: background .15s ease, transform .15s ease;
}
.np-hd__cta:hover { background: var(--np-accent-600); transform: translateY(-1px); }

/* Burger (skjult paa desktop) */
.np-hd__burger { display: none; }

/* ==========================================================================
   MOBIL
   ========================================================================== */
@media (max-width: 980px) {
	.np-hd__burger {
		display: inline-flex; flex-direction: column; gap: 5px;
		background: none; border: 0; padding: 8px; margin-left: auto; cursor: pointer;
	}
	.np-hd__burger span { width: 24px; height: 2px; background: #fff; border-radius: 2px; transition: transform .2s ease, opacity .2s ease; }
	.np-hd.is-open .np-hd__burger span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
	.np-hd.is-open .np-hd__burger span:nth-child(2) { opacity: 0; }
	.np-hd.is-open .np-hd__burger span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

	.np-hd__cta { margin-left: auto; }

	.np-hd__nav {
		position: fixed; top: var(--np-header-h); left: 0; right: 0; bottom: 0;
		background: var(--np-navy-700); overflow-y: auto;
		padding: 12px clamp(16px, 4vw, 32px) 48px;
		transform: translateX(100%); visibility: hidden;
		transition: transform .24s ease, visibility .24s ease;
	}
	.np-hd.is-open .np-hd__nav { transform: translateX(0); visibility: visible; }
	.np-hd__menu { flex-direction: column; align-items: stretch; gap: 2px; }
	.np-hd__link { font-size: 17px; padding: 14px 6px; justify-content: space-between; border-bottom: 1px solid rgba(255,255,255,.08); border-radius: 0; }

	.np-mega {
		position: static; width: auto; max-width: none;
		opacity: 1; visibility: visible; transform: none;
		background: transparent; border: 0; box-shadow: none; border-radius: 0;
		padding: 6px 0 14px 12px; display: none;
	}
	.np-hd__item--mega.is-open > .np-mega { display: block; }
	.np-hd__item--mega:hover > .np-mega { opacity: 1; visibility: visible; } /* deaktiver hover paa mobil */
	.np-hd__item--mega.is-open > .np-hd__link .np-hd__chev { transform: rotate(180deg); }
	.np-mega__grid { flex-direction: column; gap: 16px; }
}
