/* Evde Doktorum — Dark header + Mega menu (v2) */

/* ===== Header dark variant ===== */
.ed-header {
	background: linear-gradient(180deg, rgba(11, 17, 32, 0.96) 0%, rgba(25, 34, 115, 0.92) 100%);
	-webkit-backdrop-filter: saturate(180%) blur(14px);
	backdrop-filter: saturate(180%) blur(14px);
	border-bottom: 1px solid rgba(255, 255, 255, 0.08);
	box-shadow: 0 1px 0 rgba(255, 255, 255, 0.04), 0 12px 32px rgba(11, 17, 32, 0.15);
}

.ed-header.is-scrolled {
	background: linear-gradient(180deg, rgba(11, 17, 32, 0.98) 0%, rgba(17, 26, 94, 0.98) 100%);
	box-shadow: 0 8px 24px rgba(11, 17, 32, 0.28);
}

/* Topbar — tighter, accent divider underline */
.ed-topbar {
	background: rgba(0, 0, 0, 0.22);
	color: rgba(255, 255, 255, 0.82);
	border-bottom: 1px solid rgba(255, 255, 255, 0.06);
	padding: 10px 0;
	font-size: 13px;
}
.ed-topbar a { color: rgba(255, 255, 255, 0.82); }
.ed-topbar a:hover { color: var(--ed-accent); }
.ed-topbar svg { color: var(--ed-accent); }

/* Nav row */
.ed-nav { padding: 14px 0; }

.ed-brand__text { color: #fff; }
.ed-brand__text small { color: rgba(255, 255, 255, 0.62); }

/* Brand logo: when custom logo is a dark png, we render a white version via CSS filter as fallback */
.ed-brand img,
.ed-brand .ed-brand__logo {
	max-height: 46px;
	width: auto;
	filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.35));
}

/* Menu links white + tek satır */
.ed-menu > li > a {
	color: rgba(255, 255, 255, 0.92);
	font-weight: 600;
	padding: 12px 14px;
	border-radius: var(--ed-r-sm);
	position: relative;
	transition: color .2s var(--ed-ease), background .2s var(--ed-ease);
	white-space: nowrap;
	display: inline-flex;
	align-items: center;
	gap: 6px;
}
.ed-menu > li > a::after {
	content: "";
	position: absolute;
	inset-inline: 16px;
	bottom: 6px;
	height: 2px;
	background: var(--ed-accent);
	border-radius: 2px;
	transform: scaleX(0);
	transform-origin: left;
	transition: transform var(--ed-dur) var(--ed-ease);
}
.ed-menu > li:hover > a,
.ed-menu > li.current-menu-item > a,
.ed-menu > li.current-menu-parent > a,
.ed-menu > li.current-menu-ancestor > a {
	color: #fff;
	background: rgba(255, 255, 255, 0.08);
}
.ed-menu > li:hover > a::after,
.ed-menu > li.current-menu-item > a::after { transform: scaleX(1); }

/* Items with children render their own .ed-mega-arrow span — no pseudo-element needed */
.ed-menu > li.menu-item-has-children > a {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

/* ===== MEGA MENU ===== */
/* Relative positioning so the mega sits directly below the li with zero gap */
.ed-menu li.ed-has-mega { position: relative; }
.ed-menu li.ed-has-mega > a .ed-mega-arrow {
	display: inline-block;
	width: 8px; height: 8px;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg);
	margin-inline-start: 4px;
	transition: transform var(--ed-dur) var(--ed-ease);
	opacity: 0.7;
}
.ed-menu li.ed-has-mega:hover > a .ed-mega-arrow { transform: rotate(225deg); }

.ed-mega {
	position: absolute;
	top: 100%;
	left: 50%;
	transform: translateX(-50%);
	width: min(1280px, calc(100vw - 32px));
	padding-top: 0;
	background: transparent;
	color: var(--ed-body);
	display: grid;
	gap: 24px;
	grid-template-columns: 1.5fr 1fr;
	opacity: 0;
	pointer-events: none;
	transition: opacity var(--ed-dur) var(--ed-ease);
	z-index: var(--ed-z-nav);
	border: 0;
	border-radius: 0;
	box-shadow: none;
	overflow: visible;
}
/* Invisible hover bridge extending UP from mega to cover any residual gap/animation */
.ed-mega::after {
	content: "";
	position: absolute;
	inset: -24px 0 auto 0;
	height: 24px;
	pointer-events: none;
	z-index: 1;
}
.ed-has-mega:hover > .ed-mega::after,
.ed-has-mega:focus-within > .ed-mega::after {
	pointer-events: auto;
}

.ed-mega > * {
	background: var(--ed-surface);
	padding: 24px;
	border-radius: var(--ed-r-lg);
	border: 1px solid var(--ed-line);
	box-shadow: 0 24px 64px rgba(11, 17, 32, 0.22), 0 4px 12px rgba(25, 34, 115, 0.08);
	position: relative;
	overflow: hidden;
}

.ed-mega > *:first-child::before {
	content: "";
	position: absolute;
	inset: 0 auto auto 0;
	width: 100%;
	height: 3px;
	background: var(--ed-gr-accent);
	pointer-events: none;
}

.ed-menu li.ed-has-mega:hover > .ed-mega,
.ed-menu li.ed-has-mega:focus-within > .ed-mega {
	opacity: 1;
	pointer-events: auto;
}

.ed-mega__col { display: flex; flex-direction: column; gap: 16px; }
.ed-mega__heading {
	font-size: var(--ed-fs-xs);
	color: var(--ed-accent-700);
	text-transform: uppercase;
	letter-spacing: 0.1em;
	font-weight: 800;
	margin: 0 0 4px;
}

.ed-mega__grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 8px;
}

.ed-mega__link {
	display: grid;
	grid-template-columns: 40px 1fr;
	gap: 12px;
	align-items: start;
	padding: 12px;
	border-radius: var(--ed-r-md);
	color: var(--ed-ink);
	text-decoration: none;
	transition: all var(--ed-dur) var(--ed-ease);
	border: 1px solid transparent;
}
.ed-mega__link:hover {
	background: var(--ed-primary-50);
	border-color: var(--ed-primary-100);
	color: var(--ed-primary);
	transform: translateY(-1px);
}

.ed-mega__icon {
	width: 40px;
	height: 40px;
	border-radius: var(--ed-r-sm);
	background: var(--ed-primary-100);
	color: var(--ed-primary);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 40px;
	transition: all var(--ed-dur) var(--ed-ease);
}
.ed-mega__icon svg { width: 22px; height: 22px; }
.ed-mega__link:hover .ed-mega__icon {
	background: var(--ed-gr-accent);
	color: #fff;
	transform: rotate(-3deg) scale(1.03);
}

.ed-mega__text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ed-mega__title {
	font-weight: 700;
	font-size: var(--ed-fs-sm);
	color: var(--ed-ink);
	line-height: 1.35;
}
.ed-mega__desc {
	font-size: var(--ed-fs-xs);
	color: var(--ed-muted);
	line-height: 1.45;
}

.ed-mega__feature {
	background: var(--ed-gr-primary);
	color: #fff;
	border-radius: var(--ed-r-md);
	padding: 24px;
	position: relative;
	overflow: hidden;
	display: flex;
	flex-direction: column;
	gap: 12px;
	min-height: 260px;
}
.ed-mega__feature::before {
	content: "";
	position: absolute;
	inset: auto -40px -40px auto;
	width: 200px; height: 200px;
	background: radial-gradient(circle, rgba(26,204,191,0.35), transparent 60%);
	pointer-events: none;
}
.ed-mega__feature h4 {
	color: #fff;
	font-size: var(--ed-fs-lg);
	line-height: 1.25;
	margin: 0;
}
.ed-mega__feature p {
	color: rgba(255, 255, 255, 0.85);
	font-size: var(--ed-fs-sm);
	line-height: 1.55;
	margin: 0;
	flex: 1;
}
.ed-mega__feature .ed-btn { align-self: flex-start; }

/* Areas mega menu: chip grid (single wrapper) */
.ed-mega--areas { grid-template-columns: 1fr; }
.ed-mega--areas > * { padding: 28px; }
.ed-mega__chipgrid {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 6px;
}
.ed-mega__chip {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 8px 12px;
	border-radius: var(--ed-r-full);
	background: var(--ed-surface-2);
	color: var(--ed-ink-soft);
	font-size: var(--ed-fs-xs);
	font-weight: 600;
	transition: all var(--ed-dur) var(--ed-ease);
	border: 1px solid transparent;
}
.ed-mega__chip:hover {
	background: var(--ed-primary);
	color: #fff;
	transform: translateY(-2px);
	border-color: var(--ed-primary);
}
.ed-mega__chip svg {
	width: 12px; height: 12px;
	opacity: 0.6;
	transition: opacity var(--ed-dur) var(--ed-ease);
}
.ed-mega__chip:hover svg { opacity: 1; }

@media (max-width: 1199px) {
	.ed-mega { display: none; }
}

/* ===== Nav toggle dark variant ===== */
.ed-nav__toggle {
	background: rgba(255, 255, 255, 0.1);
	color: #fff;
	border: 1px solid rgba(255, 255, 255, 0.14);
}
.ed-nav__toggle:hover {
	background: var(--ed-accent);
	color: var(--ed-primary);
	border-color: var(--ed-accent);
}

/* ===== Live indicator in topbar (mevcut doktor var) ===== */
.ed-live-indicator {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-weight: 600;
	font-size: var(--ed-fs-xs);
	color: #d0f9f3;
	padding: 4px 10px;
	border-radius: var(--ed-r-full);
	background: rgba(26, 204, 191, 0.14);
	border: 1px solid rgba(26, 204, 191, 0.3);
}
.ed-live-indicator::before {
	content: "";
	width: 8px; height: 8px;
	border-radius: 50%;
	background: #10b981;
	box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.25);
	animation: ed-pulse 1.8s var(--ed-ease) infinite;
}
@keyframes ed-pulse {
	0%, 100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.45); }
	50% { box-shadow: 0 0 0 6px rgba(16, 185, 129, 0); }
}

/* ===== Header CTA overrides for dark bg ===== */
.ed-nav__cta .ed-btn--primary {
	background: var(--ed-accent);
	color: var(--ed-primary);
	border-color: var(--ed-accent);
	box-shadow: 0 6px 20px rgba(26, 204, 191, 0.3);
}
.ed-nav__cta .ed-btn--primary:hover {
	background: #fff;
	color: var(--ed-primary);
}

.ed-nav__cta .ed-btn--accent {
	background: rgba(255, 255, 255, 0.1);
	color: #fff;
	border: 1px solid rgba(255, 255, 255, 0.16);
	box-shadow: none;
}
.ed-nav__cta .ed-btn--accent:hover {
	background: #fff;
	color: var(--ed-primary);
	border-color: #fff;
}

/* Topbar social hover cleaner */
.ed-topbar__social a { background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.1); }
.ed-topbar__social a:hover { background: var(--ed-accent); color: var(--ed-primary); border-color: var(--ed-accent); }
