
/**
 * KHUTAA Core — Day/Night mode.
 * Frontend only.
 */

:root {
	--kh-theme-button-size: 40px;
	--kh-theme-button-radius: 999px;
	--kh-theme-button-bg: #fff;
	--kh-theme-button-color: #101828;
	--kh-theme-button-border: #d0d5dd;
	--kh-theme-button-hover: #f2f4f7;
	--kh-dark-bg: #0f1218;
	--kh-dark-surface: #171c24;
	--kh-dark-surface-alt: #202733;
	--kh-dark-card: #171c24;
	--kh-dark-header: #11161d;
	--kh-dark-menu: #161d26;
	--kh-dark-footer: #0b0f14;
	--kh-dark-input: #202733;
	--kh-dark-text: #f4f6f8;
	--kh-dark-muted: #aeb8c5;
	--kh-dark-border: #303947;
	--kh-dark-link: #7bb7ff;
	--kh-dark-accent: #4f9cff;
	--kh-dark-shadow-opacity: .26;
	--kh-theme-transition-duration: 220ms;
}

.khutaa-theme-controls {
	display: contents;
}

.khutaa-theme-toggle {
	position: relative;
	z-index: 1005;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 7px;
	flex: 0 0 auto;
	width: auto;
	min-width: var(--kh-theme-button-size);
	height: var(--kh-theme-button-size);
	margin: 0;
	padding: 0 11px;
	border: 1px solid var(--kh-theme-button-border);
	border-radius: var(--kh-theme-button-radius);
	color: var(--kh-theme-button-color);
	-webkit-text-fill-color: currentColor;
	background: var(--kh-theme-button-bg);
	box-shadow: 0 4px 13px rgba(15, 23, 42, .10);
	font: inherit;
	line-height: 1;
	cursor: pointer;
	appearance: none;
	transition:
		color var(--kh-theme-transition-duration) ease,
		background-color var(--kh-theme-transition-duration) ease,
		border-color var(--kh-theme-transition-duration) ease,
		transform 150ms ease,
		box-shadow 150ms ease;
}

.khutaa-theme-toggle:hover {
	color: var(--kh-theme-button-color);
	background: var(--kh-theme-button-hover);
	transform: translateY(-1px);
	box-shadow: 0 7px 18px rgba(15, 23, 42, .15);
}

.khutaa-theme-toggle:focus-visible {
	outline: 3px solid rgba(79, 156, 255, .32);
	outline-offset: 2px;
}

.khutaa-theme-toggle__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 20px;
	height: 20px;
	flex: 0 0 20px;
}

.khutaa-theme-toggle__icon svg {
	display: block;
	width: 20px;
	height: 20px;
	fill: none;
	stroke: currentColor;
	stroke-width: 1.8;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.khutaa-theme-toggle__label {
	overflow: hidden;
	max-width: 150px;
	font-size: 12px;
	font-weight: 800;
	white-space: nowrap;
}

.khutaa-theme-toggle.is-icon-only,
.khutaa-theme-toggle.is-style-icon,
.khutaa-theme-toggle.is-style-square {
	width: var(--kh-theme-button-size);
	padding: 0;
}

.khutaa-theme-toggle.is-icon-only .khutaa-theme-toggle__label,
.khutaa-theme-toggle.is-style-icon .khutaa-theme-toggle__label,
.khutaa-theme-toggle.is-style-square .khutaa-theme-toggle__label {
	display: none;
}

.khutaa-theme-toggle.is-style-square {
	border-radius: min(var(--kh-theme-button-radius), 12px);
}

.khutaa-theme-toggle.is-style-minimal {
	border-color: transparent;
	background: transparent;
	box-shadow: none;
}

.khutaa-theme-toggle.is-style-glass {
	border-color: rgba(255,255,255,.34);
	background: rgba(255,255,255,.15);
	box-shadow: 0 8px 24px rgba(15,23,42,.16);
	backdrop-filter: blur(12px);
}

.khutaa-theme-toggle.is-unplaced {
	opacity: 0;
	pointer-events: none;
}

/* 1.6.3: show the icon that matches the active mode. The former rule
 * hid the sun in light mode and could leave the control as an empty circle. */
html:not([data-khutaa-theme="dark"]) .khutaa-theme-toggle__icon--sun {
	display: inline-flex;
}
html:not([data-khutaa-theme="dark"]) .khutaa-theme-toggle__icon--moon,
html[data-khutaa-theme="dark"] .khutaa-theme-toggle__icon--sun {
	display: none;
}
html[data-khutaa-theme="dark"] .khutaa-theme-toggle__icon--moon {
	display: inline-flex;
}

html[data-khutaa-theme="dark"] .khutaa-theme-toggle {
	--kh-theme-button-bg: var(--kh-dark-surface-alt);
	--kh-theme-button-color: var(--kh-dark-text);
	--kh-theme-button-border: var(--kh-dark-border);
	--kh-theme-button-hover: var(--kh-dark-surface);
}

.khutaa-theme-toggle.is-floating-right,
.khutaa-theme-toggle.is-floating-left {
	position: fixed;
	top: 46%;
	z-index: 99990;
}

.khutaa-theme-toggle.is-floating-right {
	right: 16px;
}

.khutaa-theme-toggle.is-floating-left {
	left: 16px;
}

.khutaa-theme-toggle.is-above-mobile-nav {
	position: fixed;
	right: 14px;
	bottom: calc(82px + env(safe-area-inset-bottom, 0px));
	z-index: 99990;
}

.khutaa-theme-toggle.is-mobile-nav-position {
	flex-direction: column;
	gap: 3px;
	width: auto;
	min-width: 0;
	height: auto;
	min-height: 54px;
	padding: 6px 4px;
	border: 0;
	border-radius: 0;
	background: transparent;
	box-shadow: none;
}

.khutaa-theme-toggle.is-mobile-nav-position .khutaa-theme-toggle__icon {
	width: 22px;
	height: 22px;
}

.khutaa-theme-toggle.is-mobile-nav-position .khutaa-theme-toggle__label {
	display: block;
	max-width: 72px;
	font-size: 10px;
	font-weight: 800;
}

.khutaa-theme-toggle.is-topbar-position {
	height: 30px;
	min-width: 30px;
	padding: 0 8px;
	box-shadow: none;
}

.khutaa-theme-toggle.is-menu-position {
	margin-inline-start: auto;
}

@media (min-width: 783px) {
	.khutaa-theme-toggle--mobile {
		display: none !important;
	}
}

@media (max-width: 782px) {
	.khutaa-theme-toggle--desktop {
		display: none !important;
	}

	.khutaa-v2-brand-inner > .khutaa-theme-toggle--mobile {
		margin-inline-start: auto;
		margin-inline-end: 8px;
	}

	.khutaa-theme-toggle.is-floating-right,
	.khutaa-theme-toggle.is-floating-left {
		top: auto;
		bottom: calc(92px + env(safe-area-inset-bottom, 0px));
	}

	.khutaa-theme-toggle.is-floating-right {
		right: 12px;
	}

	.khutaa-theme-toggle.is-floating-left {
		left: 12px;
	}
}

/* Smooth transition. */
html.khutaa-theme-transitions body,
html.khutaa-theme-transitions body :where(
	header,
	nav,
	main,
	section,
	article,
	aside,
	footer,
	div,
	form,
	input,
	textarea,
	select,
	button,
	a
) {
	transition:
		background-color var(--kh-theme-transition-duration) ease,
		border-color var(--kh-theme-transition-duration) ease,
		color var(--kh-theme-transition-duration) ease,
		box-shadow var(--kh-theme-transition-duration) ease;
}

@media (prefers-reduced-motion: reduce) {
	html.khutaa-theme-transitions body,
	html.khutaa-theme-transitions body * {
		transition-duration: 0ms !important;
	}
}



/* Deterministic theme-toggle mount slots — 3.2.2 */
.khutaa-theme-slot {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	min-width: 0;
	min-height: 0;
}

.khutaa-theme-slot:empty {
	display: none;
}

.khutaa-theme-slot--desktop-header,
.khutaa-theme-slot--desktop-topbar,
.khutaa-theme-slot--desktop-main-menu {
	display: inline-flex;
}

.khutaa-theme-slot--mobile-header,
.khutaa-theme-slot--mobile-bottom-nav {
	display: none;
}

.khutaa-theme-toggle.is-header-position {
	position: relative;
	inset: auto;
	flex: 0 0 auto;
}

.khutaa-theme-toggle.is-menu-position {
	flex: 0 0 auto;
	margin-inline-start: 0;
}

.khutaa-theme-slot--mobile-bottom-nav {
	display: none;
}

@media (max-width: 782px) {
	.khutaa-theme-slot--desktop-header,
	.khutaa-theme-slot--desktop-topbar,
	.khutaa-theme-slot--desktop-main-menu {
		display: none !important;
	}

	.khutaa-theme-slot--mobile-header,
	.khutaa-theme-slot--mobile-bottom-nav {
		display: inline-flex;
	}

	.khutaa-v2-header-actions {
		display: flex !important;
		align-items: center;
		justify-content: flex-end;
		gap: 6px;
	}

	.khutaa-theme-toggle.is-header-position {
		width: var(--kh-theme-button-size);
		min-width: var(--kh-theme-button-size);
		height: var(--kh-theme-button-size);
		padding: 0;
	}

	.khutaa-theme-slot--mobile-bottom-nav {
		flex: 1 1 0;
		align-self: stretch;
	}

	.khutaa-theme-slot--mobile-bottom-nav > .khutaa-theme-toggle {
		width: 100%;
	}
}

/* ------------------------------------------------------------------
 * Dark mode: global foundations.
 * ------------------------------------------------------------------ */
html[data-khutaa-theme="dark"] {
	color-scheme: dark;
	background: var(--kh-dark-bg);
}

html[data-khutaa-theme="dark"] body,
html[data-khutaa-theme="dark"] #page,
html[data-khutaa-theme="dark"] .site,
html[data-khutaa-theme="dark"] .site-content,
html[data-khutaa-theme="dark"] .content-area,
html[data-khutaa-theme="dark"] .site-main,
html[data-khutaa-theme="dark"] .khutaa-home-builder,
html[data-khutaa-theme="dark"] .khutaa-page-shell,
html[data-khutaa-theme="dark"] .khutaa-main-wrapper {
	color: var(--kh-dark-text) !important;
	background-color: var(--kh-dark-bg) !important;
}

html[data-khutaa-theme="dark"] :where(
	h1,h2,h3,h4,h5,h6,
	.entry-title,
	.post-title,
	.widget-title,
	.section-title,
	.kh-block-title,
	.kh-section-title,
	.tie-cat-title
) {
	color: var(--kh-dark-text) !important;
}

html[data-khutaa-theme="dark"] :where(
	p,
	li,
	.entry-content,
	.post-excerpt,
	.entry-summary,
	.meta,
	.post-meta,
	.kh-meta,
	.description,
	small,
	time,
	.breadcrumb,
	.breadcrumbs
) {
	color: var(--kh-dark-muted);
}

html[data-khutaa-theme="dark"] :where(a:not(.button):not(.wp-element-button)) {
	color: var(--kh-dark-link);
}

html[data-khutaa-theme="dark"] :where(a:not(.button):not(.wp-element-button)):hover {
	color: var(--kh-dark-accent);
}

/* Surfaces, cards and common theme/Jannah containers. */
html[data-khutaa-theme="dark"] :where(
	.entry-content,
	.entry-header,
	.single-post-header,
	.post,
	.post-item,
	.kh-post-card,
	.kh-card,
	.kh-section,
	.kh-block,
	.kh-grid-item,
	.kh-carousel-item,
	.kh-media-card,
	.kh-market-bar,
	.kh-widget,
	.widget,
	.widget-content,
	.sidebar,
	.sidebar .widget,
	.container-wrapper,
	.mag-box,
	.mag-box-container,
	.stream-item,
	.pages-nav,
	.related-posts,
	.comments-area,
	.author-box,
	#related-posts,
	.archive-title,
	.category-title,
	.alkhutaa-article-summary,
	.alkhutaa-article-info,
	.alkhutaa-article-font-controls,
	.alkhutaa-share-box,
	.alkhutaa-featured-audio,
	.alkhutaa-featured-video,
	.akhlive-player-shell,
	.akhlive-channel-card,
	.akhlive-event,
	.akhlive-channel-description
) {
	color: var(--kh-dark-text) !important;
	background-color: var(--kh-dark-card) !important;
	border-color: var(--kh-dark-border) !important;
	box-shadow: 0 12px 34px rgba(0,0,0,var(--kh-dark-shadow-opacity)) !important;
}

/* Alternate surfaces. */
html[data-khutaa-theme="dark"] :where(
	.kh-section:nth-child(even),
	.kh-block-header,
	.kh-card-footer,
	.post-meta,
	.entry-meta,
	.pages-nav,
	.alkhutaa-summary-toggle,
	.alk-mobile-panel-item,
	.alk-mobile-sheet__head,
	.akhlive-browser-tools,
	.akhlive-rights-notice
) {
	background-color: var(--kh-dark-surface-alt) !important;
	border-color: var(--kh-dark-border) !important;
}

/* Header and menus. */
html[data-khutaa-theme="dark"] :where(
	.khutaa-v2-header,
	.khutaa-v2-brand-row,
	.khutaa-v2-brand-inner,
	.khutaa-v2-topbar,
	.khutaa-v2-topbar-inner,
	.site-header,
	#theme-header,
	.main-nav,
	.main-menu-wrapper
) {
	color: var(--kh-dark-text) !important;
	background-color: var(--kh-dark-header) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] :where(
	.khutaa-v2-main-nav,
	.khutaa-v2-main-nav-inner,
	.khutaa-v2-desktop-menu,
	.khutaa-v2-submenu,
	.khutaa-v2-mobile-menu,
	.khutaa-v2-search-modal,
	.khutaa-v2-search-panel,
	.main-menu,
	.main-menu ul,
	.main-menu .sub-menu,
	.tie-popup
) {
	color: var(--kh-dark-text) !important;
	background-color: var(--kh-dark-menu) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] :where(
	.khutaa-v2-main-nav a,
	.khutaa-v2-topbar a,
	.khutaa-v2-desktop-menu a,
	.khutaa-v2-submenu a,
	.main-menu a
) {
	color: var(--kh-dark-text) !important;
}

html[data-khutaa-theme="dark"] :where(
	.khutaa-v2-main-nav a:hover,
	.khutaa-v2-desktop-menu a:hover,
	.khutaa-v2-submenu a:hover
) {
	color: var(--kh-dark-link) !important;
	background-color: var(--kh-dark-surface-alt) !important;
}

html[data-khutaa-theme="dark"] .khutaa-v2-header-logo img {
	filter: none;
}

/* News ticker and market bars. */
html[data-khutaa-theme="dark"] :where(
	.khutaa-news-ticker,
	.khutaa-news-ticker__inner,
	.khutaa-v2-header-latest,
	.khutaa-v2-header-latest-inner,
	.khutaa-market-bar,
	.market-bar,
	.breaking-news
) {
	color: var(--kh-dark-text) !important;
	background-color: var(--kh-dark-surface) !important;
	border-color: var(--kh-dark-border) !important;
}

/* Article. */
html[data-khutaa-theme="dark"] :where(
	.single-post .entry-content,
	.single-post .post-content,
	.single-post .entry-header,
	.single-post .single-post-header,
	.article-content,
	.article-header,
	.article-body
) {
	color: var(--kh-dark-text) !important;
	background-color: var(--kh-dark-card) !important;
}

html[data-khutaa-theme="dark"] :where(
	.entry-content blockquote,
	.post-content blockquote,
	.entry-content pre,
	.entry-content code,
	.post-content pre,
	.post-content code
) {
	color: var(--kh-dark-text) !important;
	background-color: var(--kh-dark-surface-alt) !important;
	border-color: var(--kh-dark-accent) !important;
}

/* Inputs, selects and forms. */
html[data-khutaa-theme="dark"] :where(
	input,
	textarea,
	select,
	option,
	.search-field,
	.search-input,
	.comment-form input,
	.comment-form textarea
) {
	color: var(--kh-dark-text) !important;
	-webkit-text-fill-color: var(--kh-dark-text) !important;
	background-color: var(--kh-dark-input) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] :where(input,textarea,select)::placeholder {
	color: var(--kh-dark-muted) !important;
	opacity: .8;
}

/* Tables. */
html[data-khutaa-theme="dark"] :where(table,thead,tbody,tfoot,tr,th,td) {
	color: var(--kh-dark-text) !important;
	background-color: var(--kh-dark-card) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] :where(th) {
	background-color: var(--kh-dark-surface-alt) !important;
}

/* Footer. */
html[data-khutaa-theme="dark"] :where(
	.site-footer,
	#footer,
	footer,
	.khutaa-footer,
	.khutaa-mobile-footer,
	.footer-widget-area,
	.footer-bottom
) {
	color: var(--kh-dark-text) !important;
	background-color: var(--kh-dark-footer) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] :where(
	.site-footer a,
	#footer a,
	.khutaa-footer a,
	.khutaa-mobile-footer a
) {
	color: var(--kh-dark-muted) !important;
}

html[data-khutaa-theme="dark"] :where(
	.site-footer a:hover,
	#footer a:hover,
	.khutaa-footer a:hover
) {
	color: var(--kh-dark-link) !important;
}

/* Mobile UI. */
html[data-khutaa-theme="dark"] :where(
	.alk-mobile-bottom-nav,
	.alk-mobile-sheet,
	.alk-mobile-panel,
	.alk-mobile-overlay,
	.alk-mobile-panel__items,
	.alk-mobile-panel-item,
	.alk-mobile-feed-status
) {
	color: var(--kh-dark-text) !important;
	background-color: var(--kh-dark-surface) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] :where(
	.alk-mobile-nav-item,
	.alk-mobile-nav-item b,
	.alk-mobile-sheet__head h3,
	.alk-mobile-panel-item__copy strong
) {
	color: var(--kh-dark-text) !important;
}

html[data-khutaa-theme="dark"] .alk-mobile-overlay {
	background-color: rgba(0,0,0,.68) !important;
}

/* Buttons. */
html[data-khutaa-theme="dark"] :where(
	.button,
	button:not(.khutaa-theme-toggle):not(.alk-mobile-nav-item),
	.wp-element-button
) {
	border-color: var(--kh-dark-border);
}

html[data-khutaa-theme="dark"] :where(
	.button:not(.button-primary),
	button:not(.khutaa-theme-toggle):not(.alk-mobile-nav-item):not([class*="primary"])
) {
	color: var(--kh-dark-text);
	background-color: var(--kh-dark-surface-alt);
}

/* Scrollbars where supported. */
html[data-khutaa-theme="dark"] {
	scrollbar-color: var(--kh-dark-border) var(--kh-dark-bg);
}

html[data-khutaa-theme="dark"] ::selection {
	color: #fff;
	background: var(--kh-dark-accent);
}


/* ------------------------------------------------------------------
 * KHUTAA full dark coverage — 3.2.2
 * Uses explicit selectors to override the header's generated ID styles.
 * ------------------------------------------------------------------ */
html[data-khutaa-theme="dark"] body {
	--kh-text: var(--kh-dark-text);
	--kh-muted: var(--kh-dark-muted);
}

/* Header root and generated header instance. */
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"],
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-header,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-brand-row,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-brand-inner {
	color: var(--kh-dark-text) !important;
	background: var(--kh-dark-header) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-topbar,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-topbar-inner {
	color: var(--kh-dark-text) !important;
	background: var(--kh-dark-footer) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-topbar-info,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-topbar-info a,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-date {
	color: var(--kh-dark-muted) !important;
}

html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-search-button,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-mobile-menu-button {
	color: var(--kh-dark-text) !important;
	background: var(--kh-dark-surface-alt) !important;
	border-color: var(--kh-dark-border) !important;
	box-shadow: 0 4px 14px rgba(0,0,0,var(--kh-dark-shadow-opacity)) !important;
}

html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-mobile-menu-button span {
	background: var(--kh-dark-text) !important;
}

html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-main-nav,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-main-nav-inner,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-desktop-menu {
	color: var(--kh-dark-text) !important;
	background: var(--kh-dark-menu) !important;
	border-color: var(--kh-dark-border) !important;
	box-shadow: none !important;
}

html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-desktop-menu > li > a,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-menu-title,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-menu-icon,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-menu-arrow {
	color: var(--kh-dark-text) !important;
}

html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-desktop-menu > li:hover > a,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-desktop-menu > li.is-current > a {
	color: var(--kh-dark-link) !important;
	background: var(--kh-dark-surface-alt) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-submenu,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-submenu li,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-submenu a {
	color: var(--kh-dark-text) !important;
	background: var(--kh-dark-surface) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-submenu a:hover {
	color: var(--kh-dark-link) !important;
	background: var(--kh-dark-surface-alt) !important;
}

/* Header latest-news strip and every generated child. */
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-header-latest,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-header-latest-inner,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-latest-window,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-latest-track {
	color: var(--kh-dark-text) !important;
	background: var(--kh-dark-surface) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-latest-track a {
	color: var(--kh-dark-text) !important;
	background: var(--kh-dark-surface) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-latest-track a:hover {
	color: var(--kh-dark-link) !important;
	background: var(--kh-dark-surface-alt) !important;
}

html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-latest-track time {
	color: var(--kh-dark-muted) !important;
	background: var(--kh-dark-surface-alt) !important;
}

/* Search overlay and mobile drawer. */
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-search-overlay,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-search-form,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-mobile-drawer,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-mobile-drawer-head,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-mobile-menu,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-mobile-menu-item,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-mobile-menu-row,
html[data-khutaa-theme="dark"] [id^="khutaa-v2-header-"] .khutaa-v2-mobile-submenu {
	color: var(--kh-dark-text) !important;
	background: var(--kh-dark-surface) !important;
	border-color: var(--kh-dark-border) !important;
}

/* Standalone news ticker variables override its inline light settings. */
html[data-khutaa-theme="dark"] .khutaa-news-ticker {
	--kh-ticker-bg: var(--kh-dark-surface) !important;
	--kh-ticker-text: var(--kh-dark-text) !important;
	--kh-ticker-border: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] .khutaa-news-ticker .khutaa-ticker-shell,
html[data-khutaa-theme="dark"] .khutaa-news-ticker .khutaa-ticker-viewport,
html[data-khutaa-theme="dark"] .khutaa-news-ticker .khutaa-ticker-track {
	background: var(--kh-dark-surface) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] .khutaa-news-ticker .khutaa-ticker-item {
	color: var(--kh-dark-text) !important;
}

html[data-khutaa-theme="dark"] .khutaa-news-ticker .khutaa-ticker-item time {
	color: var(--kh-dark-muted) !important;
}

/* Advertising wrappers and placeholders. */
html[data-khutaa-theme="dark"] .alk-ad,
html[data-khutaa-theme="dark"] .alk-ad__inner,
html[data-khutaa-theme="dark"] .kh-widget-ad,
html[data-khutaa-theme="dark"] [data-ad-slot] {
	color: var(--kh-dark-text) !important;
	background-color: var(--kh-dark-surface) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] .alk-ad__label,
html[data-khutaa-theme="dark"] .kh-widget-ad__label {
	color: var(--kh-dark-muted) !important;
	background: var(--kh-dark-surface-alt) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] .alk-ad__inner :where(
	.ad-placeholder,
	.ad-demo,
	.placeholder,
	[class*="advert-placeholder"],
	[class*="ad-placeholder"]
) {
	color: var(--kh-dark-text) !important;
	background: var(--kh-dark-surface-alt) !important;
	border-color: var(--kh-dark-border) !important;
}

/* Builder sections, cards, lists and text surfaces. */
html[data-khutaa-theme="dark"] :where(
	.alk-container,
	.alk-section,
	.alk-card__content,
	.alk-card__meta,
	.khutaa-builder-row-front,
	.khutaa-headline-list,
	.khutaa-col2-headlines,
	.khutaa-col3-headlines,
	.khutaa-news-list,
	.khutaa-side-list,
	.khutaa-compact-list,
	.khutaa-ranked-list,
	.khutaa-timeline-list,
	.khutaa-newspaper-columns,
	.khutaa-newsroom-layout,
	.khutaa-newsroom-side,
	.khutaa-newsroom-footer,
	.khutaa-post-layout,
	.khutaa-media-block,
	.khutaa-media-hub,
	.khutaa-news-carousel,
	.khutaa-builder-sidebar-slot
) {
	color: var(--kh-dark-text) !important;
	background-color: var(--kh-dark-bg) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] :where(
	.alk-card,
	.alk-post-card,
	.alk-card__content,
	.khutaa-feature-story,
	.khutaa-feature-copy,
	.khutaa-col2-card-grid > *,
	.khutaa-mini-grid > *,
	.khutaa-media-card,
	.khutaa-media-hub-list-item,
	.khutaa-audio-radio,
	.khutaa-audio-studio,
	.khutaa-audio-wave-list > *,
	.khutaa-audio-playlist > *,
	.khutaa-video-playlist > *,
	.khutaa-editors-ranked > *,
	.khutaa-ranked-list > *,
	.khutaa-headline-list > *,
	.khutaa-side-list > *,
	.khutaa-news-list > *
) {
	color: var(--kh-dark-text) !important;
	background-color: var(--kh-dark-card) !important;
	border-color: var(--kh-dark-border) !important;
	box-shadow: 0 10px 28px rgba(0,0,0,var(--kh-dark-shadow-opacity)) !important;
}

html[data-khutaa-theme="dark"] :where(
	.alk-card__content a,
	.khutaa-feature-copy a,
	.khutaa-headline-list a,
	.khutaa-side-list a,
	.khutaa-news-list a,
	.khutaa-ranked-list a
) {
	color: var(--kh-dark-text) !important;
}

html[data-khutaa-theme="dark"] :where(
	.alk-card__content a:hover,
	.khutaa-feature-copy a:hover,
	.khutaa-headline-list a:hover,
	.khutaa-side-list a:hover,
	.khutaa-news-list a:hover,
	.khutaa-ranked-list a:hover
) {
	color: var(--kh-dark-link) !important;
}

/* WordPress/Jannah wrapper layers that can otherwise stay white. */
html[data-khutaa-theme="dark"] :where(
	.background-overlay,
	#content,
	.content,
	.main-content,
	.main-content-row,
	.container,
	.container-fluid,
	.section-wrapper,
	.post-wrapper,
	.entry-wrapper
) {
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] :where(
	.container-wrapper,
	.mag-box,
	.mag-box-container,
	.widget,
	.sidebar .widget,
	.post-wrapper,
	.entry-wrapper
) {
	background-color: var(--kh-dark-card) !important;
}


/* Advanced toggle positions — 3.2.3 */
.khutaa-theme-adjacent-slot,
.khutaa-theme-edge-slot {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	min-width: 0;
	min-height: 0;
	list-style: none;
}

.khutaa-theme-adjacent-slot > .khutaa-theme-toggle,
.khutaa-theme-edge-slot > .khutaa-theme-toggle {
	margin: 0 5px;
}

.khutaa-v2-desktop-menu > .khutaa-theme-adjacent-slot {
	display: flex;
	align-items: stretch;
}

.khutaa-v2-desktop-menu > .khutaa-theme-adjacent-slot > .khutaa-theme-toggle {
	align-self: center;
	height: 38px;
	margin: 0 5px;
}

.khutaa-theme-toggle.is-live-adjacent {
	box-shadow: 0 4px 14px rgba(15,23,42,.13);
}

.khutaa-theme-toggle.is-search-adjacent,
.khutaa-theme-toggle.is-menu-button-adjacent {
	margin-inline: 4px;
}

.khutaa-theme-toggle.is-logo-adjacent {
	margin-inline: 8px;
}

.alk-mobile-bottom-nav > .khutaa-theme-adjacent-slot,
.alkhutaa-mobile-bottom-nav > .khutaa-theme-adjacent-slot {
	flex: 1 1 0;
	align-self: stretch;
}

.alk-mobile-bottom-nav > .khutaa-theme-adjacent-slot > .khutaa-theme-toggle,
.alkhutaa-mobile-bottom-nav > .khutaa-theme-adjacent-slot > .khutaa-theme-toggle {
	width: 100%;
	height: 100%;
	min-width: 0;
	padding: 5px 3px;
	border: 0;
	border-radius: 0;
	background: transparent;
	box-shadow: none;
}

.khutaa-v2-mobile-menu .khutaa-theme-adjacent-slot {
	display: flex;
	padding: 6px 10px;
}

@media (max-width: 782px) {
	.khutaa-theme-adjacent-slot--desktop {
		display: none !important;
	}

	.khutaa-theme-toggle.is-live-adjacent,
	.khutaa-theme-toggle.is-search-adjacent,
	.khutaa-theme-toggle.is-menu-button-adjacent {
		width: var(--kh-theme-button-size);
		min-width: var(--kh-theme-button-size);
		height: var(--kh-theme-button-size);
		padding: 0;
	}

	.khutaa-theme-toggle.is-live-adjacent .khutaa-theme-toggle__label,
	.khutaa-theme-toggle.is-search-adjacent .khutaa-theme-toggle__label,
	.khutaa-theme-toggle.is-menu-button-adjacent .khutaa-theme-toggle__label {
		display: none;
	}
}


/* Screenshot-targeted dark coverage — 3.2.3 */
html[data-khutaa-theme="dark"] body.home,
html[data-khutaa-theme="dark"] body.page,
html[data-khutaa-theme="dark"] body.single-post,
html[data-khutaa-theme="dark"] body.archive {
	background: var(--kh-dark-bg) !important;
}

/* Inline CSS variables used by KHUTAA article tools. */
html[data-khutaa-theme="dark"] .alk-article-info {
	--alk-info-bg: var(--kh-dark-card) !important;
	--alk-info-border: var(--kh-dark-border) !important;
	--alk-info-icon: var(--kh-dark-accent) !important;
	color: var(--kh-dark-text) !important;
	background: var(--kh-dark-card) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] .alk-article-info__title,
html[data-khutaa-theme="dark"] .alk-article-info__item strong,
html[data-khutaa-theme="dark"] .alk-author-box h3 {
	color: var(--kh-dark-text) !important;
}

html[data-khutaa-theme="dark"] .alk-article-info__item,
html[data-khutaa-theme="dark"] .alk-author-box p {
	color: var(--kh-dark-muted) !important;
	background: var(--kh-dark-surface-alt) !important;
	border-color: var(--kh-dark-border) !important;
}

/* Article share bar and legacy article header tools. */
html[data-khutaa-theme="dark"] :where(
	.alk-share,
	.alk-share__buttons,
	.kh-article-toolbar,
	.kh-toolbar-actions,
	.kh-toolbar-share,
	.kh-share-links,
	.kh-summary-box,
	.kh-article-header,
	.kh-article-head
) {
	color: var(--kh-dark-text) !important;
	background: var(--kh-dark-card) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] :where(
	.kh-article-tool,
	.alk-share-button,
	.alk-copy-button,
	.alk-font-controls,
	.alk-font-controls button,
	.alk-article-summary__toggle
) {
	color: var(--kh-dark-text) !important;
	background: var(--kh-dark-surface-alt) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] :where(
	.kh-share-title,
	.kh-article-meta,
	.kh-meta-item,
	.alk-share__title,
	.alk-share-label
) {
	color: var(--kh-dark-muted) !important;
}

/* Summary variables and panels. */
html[data-khutaa-theme="dark"] .alk-article-summary {
	--alk-summary-bg: var(--kh-dark-card) !important;
	--alk-summary-text: var(--kh-dark-muted) !important;
	--alk-summary-title: var(--kh-dark-text) !important;
	--alk-summary-border: var(--kh-dark-border) !important;
	--alk-summary-toggle-bg: var(--kh-dark-surface-alt) !important;
	--alk-summary-toggle-color: var(--kh-dark-text) !important;
	--alk-summary-toggle-border: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] :where(
	.alk-article-summary__panel,
	.alk-article-summary__body,
	.alk-article-summary__text
) {
	color: var(--kh-dark-muted) !important;
	background: var(--kh-dark-card) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] .alk-article-summary__title {
	color: var(--kh-dark-text) !important;
}

/* Related stories, tags and article footer. */
html[data-khutaa-theme="dark"] :where(
	.alk-related,
	.alk-related__grid,
	.alk-related__grid > article,
	.alk-related__grid > a,
	.post-bottom-meta,
	.entry-footer,
	.post-tags,
	.tagcloud,
	.single-post article#the-post,
	.single-post .post-inner,
	.single-post .entry-wrapper
) {
	color: var(--kh-dark-text) !important;
	background-color: var(--kh-dark-card) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] :where(
	.post-tags a,
	.tagcloud a,
	.alk-related a
) {
	color: var(--kh-dark-text) !important;
	background: var(--kh-dark-surface-alt) !important;
	border-color: var(--kh-dark-border) !important;
}

/* Advertising placeholders while preserving real ad images. */
html[data-khutaa-theme="dark"] .alk-ad,
html[data-khutaa-theme="dark"] .alk-ad__inner {
	color: var(--kh-dark-text) !important;
	background: var(--kh-dark-surface) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] .alk-ad__inner > :not(img):not(picture):not(video):not(iframe),
html[data-khutaa-theme="dark"] .alk-ad__inner [style*="background"] {
	color: var(--kh-dark-text) !important;
	background-color: var(--kh-dark-surface-alt) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] .alk-ad__inner :where(h1,h2,h3,h4,h5,h6,strong,p,span,small) {
	color: inherit !important;
}

/* Old breaking-news and mobile snippets still used by the site. */
html[data-khutaa-theme="dark"] :where(
	.khbp-card,
	.khbp-card-body,
	.khbp-loading,
	.alkhutaa-breaking-panel,
	.alkhutaa-mobile-cats-panel,
	.alkhutaa-mobile-services-panel,
	.alkhutaa-mobile-latest-panel,
	.alkhutaa-more-menu,
	.alkhutaa-latest-list a,
	.alkhutaa-mobile-cat-link,
	.alkhutaa-more-btn
) {
	color: var(--kh-dark-text) !important;
	background: var(--kh-dark-card) !important;
	border-color: var(--kh-dark-border) !important;
}

html[data-khutaa-theme="dark"] :where(
	.khbp-card-body,
	.khbp-loading,
	.alkhutaa-latest-list a,
	.alkhutaa-mobile-cat-link,
	.alkhutaa-more-btn,
	.alkhutaa-more-menu a
) {
	color: var(--kh-dark-text) !important;
	background: var(--kh-dark-surface-alt) !important;
	border-color: var(--kh-dark-border) !important;
}

/* Generic bounded audit class for near-white legacy surfaces. */
html[data-khutaa-theme="dark"] .khutaa-dark-auto-surface {
	color: var(--kh-dark-text) !important;
	background-color: var(--kh-dark-card) !important;
	border-color: var(--kh-dark-border) !important;
	box-shadow: 0 8px 24px rgba(0,0,0,var(--kh-dark-shadow-opacity)) !important;
}

html[data-khutaa-theme="dark"] .khutaa-dark-auto-surface :where(
	h1,h2,h3,h4,h5,h6,strong,a,button
) {
	color: var(--kh-dark-text) !important;
}

html[data-khutaa-theme="dark"] .khutaa-dark-auto-surface :where(
	p,span,small,time,li
) {
	color: var(--kh-dark-muted) !important;
}

/* Existing live-button components keep their identity in dark mode. */
html[data-khutaa-theme="dark"] :where(
	.khutaa-live-menu-item > a,
	.khutaa-live-mobile-link,
	.khutaa-v2-live-button,
	.khutaa-live-button
) {
	color: #fff !important;
}


/* KHUTAA Core 3.3.0 — direct server-side placement */
.khutaa-theme-toggle.is-server-placed{position:relative;inset:auto;opacity:1;pointer-events:auto}
.khutaa-theme-toggle.is-server-placed.is-topbar-position{height:30px;min-width:30px;padding:0 8px;box-shadow:none}
.khutaa-theme-toggle.is-server-placed.is-menu-position{height:38px;align-self:center}
.khutaa-theme-toggle.is-server-placed.is-live-adjacent,
.khutaa-theme-toggle.is-server-placed.is-search-adjacent,
.khutaa-theme-toggle.is-server-placed.is-logo-adjacent,
.khutaa-theme-toggle.is-server-placed.is-menu-button-adjacent{margin-inline:4px}
.khutaa-theme-toggle.is-server-placed.is-drawer-position{width:calc(100% - 20px);margin:7px 10px}

@media(max-width:782px){
	.khutaa-theme-toggle.is-server-placed:not(.is-mobile-nav-position):not(.is-drawer-position){
		width:var(--kh-theme-button-size);min-width:var(--kh-theme-button-size);height:var(--kh-theme-button-size);padding:0
	}
	.khutaa-theme-toggle.is-server-placed:not(.is-drawer-position) .khutaa-theme-toggle__label{display:none}
}

/* Internal theme variables used by builder/article/mobile components */
html[data-khutaa-theme="dark"] body{
	--alk-bg:var(--kh-dark-bg)!important;
	--alk-page-bg:var(--kh-dark-bg)!important;
	--alk-surface:var(--kh-dark-surface)!important;
	--alk-surface-alt:var(--kh-dark-surface-alt)!important;
	--alk-card:var(--kh-dark-card)!important;
	--alk-border:var(--kh-dark-border)!important;
	--alk-text:var(--kh-dark-text)!important;
	--alk-muted:var(--kh-dark-muted)!important;
	--alk-primary:var(--kh-dark-accent)!important;
	--kh-bg:var(--kh-dark-bg)!important;
	--kh-surface:var(--kh-dark-surface)!important;
	--kh-card:var(--kh-dark-card)!important;
	--kh-border:var(--kh-dark-border)!important;
	--kh-text:var(--kh-dark-text)!important;
	--kh-muted:var(--kh-dark-muted)!important
}

/* Old snippets with inline white backgrounds */
html[data-khutaa-theme="dark"] :where(
	[style*="background:#fff"],[style*="background: #fff"],
	[style*="background:#ffffff"],[style*="background: #ffffff"],
	[style*="background-color:#fff"],[style*="background-color: #fff"],
	[style*="background-color:#ffffff"],[style*="background-color: #ffffff"],
	[style*="background:white"],[style*="background: white"],
	[style*="background-color:white"],[style*="background-color: white"],
	[style*="background:rgb(255, 255, 255)"],
	[style*="background-color:rgb(255, 255, 255)"]
):not(img):not(video):not(iframe):not(.khutaa-v2-live-button){
	color:var(--kh-dark-text)!important;
	background-color:var(--kh-dark-card)!important;
	border-color:var(--kh-dark-border)!important
}

html[data-khutaa-theme="dark"] .khutaa-dark-auto-surface{
	color:var(--kh-dark-text)!important;
	background-color:var(--kh-dark-card)!important;
	border-color:var(--kh-dark-border)!important;
	box-shadow:0 8px 24px rgba(0,0,0,var(--kh-dark-shadow-opacity))!important
}
html[data-khutaa-theme="dark"] .khutaa-dark-auto-surface :where(h1,h2,h3,h4,h5,h6,strong,a){
	color:var(--kh-dark-text)!important
}
html[data-khutaa-theme="dark"] .khutaa-dark-auto-surface :where(p,span,small,time,li){
	color:var(--kh-dark-muted)!important
}

/* Generated explicit-white component overrides */
html[data-khutaa-theme="dark"] .kh-widget-weather--gradient,
html[data-khutaa-theme="dark"] .kh-widget-weather--card,
html[data-khutaa-theme="dark"] .kh-widget-ad__label,
html[data-khutaa-theme="dark"] .kh-widget-social--primary a,
html[data-khutaa-theme="dark"] .kh-widget-social--dark a,
html[data-khutaa-theme="dark"] .kh-widget-social--brand .kh-social-facebook,
html[data-khutaa-theme="dark"] .kh-widget-social--brand .kh-social-x,
html[data-khutaa-theme="dark"] .kh-widget-social--brand .kh-social-instagram,
html[data-khutaa-theme="dark"] .kh-widget-social--brand .kh-social-youtube,
html[data-khutaa-theme="dark"] .kh-widget-social--brand .kh-social-telegram,
html[data-khutaa-theme="dark"] .kh-widget-social--brand .kh-social-whatsapp,
html[data-khutaa-theme="dark"] .kh-widget-social--brand .kh-social-tiktok,
html[data-khutaa-theme="dark"] .kh-widget-social--brand .kh-social-linkedin,
html[data-khutaa-theme="dark"] .kh-widget-social--brand .kh-social-rss,
html[data-khutaa-theme="dark"] .kh-widget-social--brand .kh-social-email,
html[data-khutaa-theme="dark"] .kh-widget-post__media,
html[data-khutaa-theme="dark"] .kh-widget-posts--numbered .kh-widget-post>a:before,
html[data-khutaa-theme="dark"] .kh-widget-tabs,
html[data-khutaa-theme="dark"] .kh-widget-tabs__nav button.is-active,
html[data-khutaa-theme="dark"] .kh-widget-categories a,
html[data-khutaa-theme="dark"] .kh-widget-video__fallback,
html[data-khutaa-theme="dark"] .kh-widget-newsletter form,
html[data-khutaa-theme="dark"] .kh-widget-newsletter button,
html[data-khutaa-theme="dark"] .alk-widget-zone--footer,
html[data-khutaa-theme="dark"] .alk-widget-zone--footer .kh-widget-categories a,
html[data-khutaa-theme="dark"] .alk-widget-zone--footer .kh-widget-post>a,
html[data-khutaa-theme="dark"] .alk-widget-zone--footer .kh-widget-rss__item,
html[data-khutaa-theme="dark"] .kh-pro-post__link,
html[data-khutaa-theme="dark"] .kh-pro-post__placeholder,
html[data-khutaa-theme="dark"] .kh-pro-posts--numbered .kh-pro-post__link:before,
html[data-khutaa-theme="dark"] .kh-pro-posts--timeline .kh-pro-post:before,
html[data-khutaa-theme="dark"] .kh-widget-slider__prev,
html[data-khutaa-theme="dark"] .kh-widget-slider__next,
html[data-khutaa-theme="dark"] .kh-widget-slider__dots button.is-active,
html[data-khutaa-theme="dark"] .kh-widget-slider--split{color:var(--kh-dark-text)!important;background-color:var(--kh-dark-card)!important;border-color:var(--kh-dark-border)!important}

/* Generated explicit-white component overrides */
html[data-khutaa-theme="dark"] .kh-widget-play,
html[data-khutaa-theme="dark"] .kh-widget-audio__item,
html[data-khutaa-theme="dark"] .kh-widget-gallery strong,
html[data-khutaa-theme="dark"] .kh-widget-comments-pro>a,
html[data-khutaa-theme="dark"] .kh-widget-tags a small,
html[data-khutaa-theme="dark"] .kh-widget-poll,
html[data-khutaa-theme="dark"] .kh-widget-poll button,
html[data-khutaa-theme="dark"] .kh-widget-poll--dark,
html[data-khutaa-theme="dark"] .kh-widget-about a,
html[data-khutaa-theme="dark"] .kh-widget-about--dark,
html[data-khutaa-theme="dark"] .kh-widget-social-stats--brand>a,
html[data-khutaa-theme="dark"] .kh-widget-social-stats--brand .kh-widget-social-stats__icon,
html[data-khutaa-theme="dark"] .kh-widget-links--buttons a,
html[data-khutaa-theme="dark"] .kh-widget-links--buttons a span,
html[data-khutaa-theme="dark"] .kh-widget-search button,
html[data-khutaa-theme="dark"] .kh-widget-search--dark input,
html[data-khutaa-theme="dark"] .kh-widget-clock,
html[data-khutaa-theme="dark"] .kh-widget-clock--dark,
html[data-khutaa-theme="dark"] .kh-widget-mini-ticker__label,
html[data-khutaa-theme="dark"] .khutaa-v2-slide-category,
html[data-khutaa-theme="dark"] .khutaa-v2-arrow,
html[data-khutaa-theme="dark"] .khutaa-v2-dot.is-active,
html[data-khutaa-theme="dark"] .khutaa-v2-side-card,
html[data-khutaa-theme="dark"] .khutaa-v2-image-fallback,
html[data-khutaa-theme="dark"] .khutaa-slider-layout-6 .khutaa-v2-side-text,
html[data-khutaa-theme="dark"] .khutaa-slider-layout-9 .khutaa-v2-side-card,
html[data-khutaa-theme="dark"] .khutaa-ticker-shell,
html[data-khutaa-theme="dark"] .khutaa-ticker-label,
html[data-khutaa-theme="dark"] .khutaa-ticker-viewport,
html[data-khutaa-theme="dark"] .khutaa-ticker-style-primary .khutaa-ticker-label,
html[data-khutaa-theme="dark"] .khutaa-ticker-style-gradient .khutaa-ticker-shell,
html[data-khutaa-theme="dark"] .khutaa-ticker-style-glass .khutaa-ticker-shell,
html[data-khutaa-theme="dark"] .khutaa-ticker-breaking-badge,
html[data-khutaa-theme="dark"] .khutaa-builder-item,
html[data-khutaa-theme="dark"] .khutaa-builder-empty{color:var(--kh-dark-text)!important;background-color:var(--kh-dark-card)!important;border-color:var(--kh-dark-border)!important}

/* Generated explicit-white component overrides */
html[data-khutaa-theme="dark"] .khutaa-block-dialog,
html[data-khutaa-theme="dark"] .khutaa-block-dialog>header,
html[data-khutaa-theme="dark"] .khutaa-block-dialog>footer,
html[data-khutaa-theme="dark"] .khutaa-modal-tabs button.is-active,
html[data-khutaa-theme="dark"] .preview-kind-hero.layout-5 i:nth-child(2),
html[data-khutaa-theme="dark"] .preview-kind-media.preview-kind-video i:first-child:after,
html[data-khutaa-theme="dark"] .preview-kind-media.preview-kind-audio i:first-child:after,
html[data-khutaa-theme="dark"] .preview-kind-media.preview-kind-image i:first-child:after,
html[data-khutaa-theme="dark"] .khutaa-media-hub-admin-preview,
html[data-khutaa-theme="dark"] .khutaa-builder-section,
html[data-khutaa-theme="dark"] .khutaa-section-head,
html[data-khutaa-theme="dark"] .khutaa-section-actions .button,
html[data-khutaa-theme="dark"] .khutaa-builder-actions .button,
html[data-khutaa-theme="dark"] .khutaa-section-placeholder,
html[data-khutaa-theme="dark"] .khutaa-section-dialog,
html[data-khutaa-theme="dark"] .khutaa-section-layout-choice,
html[data-khutaa-theme="dark"] /* Alkhutaa 2.3.0 — مجموعات أشكال العرض الكامل والثنائي والثلاثي. */
.khutaa-layout-group,
html[data-khutaa-theme="dark"] /* Alkhutaa 2.3.1 — اختيار آمن لأشكال البلوكات ومنع الشاشة البيضاء. */
.khutaa-layout-choice,
html[data-khutaa-theme="dark"] .khutaa-layout-choice.is-selected:after,
html[data-khutaa-theme="dark"] .khutaa-layout-more,
html[data-khutaa-theme="dark"] .khutaa-add-preset,
html[data-khutaa-theme="dark"] .khutaa-demos-hero,
html[data-khutaa-theme="dark"] .khutaa-demo-toolbar,
html[data-khutaa-theme="dark"] .khutaa-demo-card,
html[data-khutaa-theme="dark"] .khutaa-demo-active-badge,
html[data-khutaa-theme="dark"] .khutaa-market-strip>div,
html[data-khutaa-theme="dark"] .khutaa-post-layout-3 .khutaa-news-card,
html[data-khutaa-theme="dark"] .khutaa-news-card.is-timeline:before,
html[data-khutaa-theme="dark"] .khutaa-carousel-arrow,
html[data-khutaa-theme="dark"] .khutaa-post-layout-27,
html[data-khutaa-theme="dark"] .khutaa-breaking-board>.is-compact,
html[data-khutaa-theme="dark"] .khutaa-media-feature,
html[data-khutaa-theme="dark"] .khutaa-media-symbol,
html[data-khutaa-theme="dark"] .khutaa-media-card,
html[data-khutaa-theme="dark"] .khutaa-media-cinema{color:var(--kh-dark-text)!important;background-color:var(--kh-dark-card)!important;border-color:var(--kh-dark-border)!important}

/* Generated explicit-white component overrides */
html[data-khutaa-theme="dark"] .khutaa-media-kind-audio .khutaa-media-card,
html[data-khutaa-theme="dark"] .khutaa-media-kind-audio .khutaa-media-feature,
html[data-khutaa-theme="dark"] .alk-video-badge,
html[data-khutaa-theme="dark"] .khutaa-media-card.is-overlay,
html[data-khutaa-theme="dark"] .khutaa-media-card.is-overlay .khutaa-media-copy,
html[data-khutaa-theme="dark"] .khutaa-image-editorial>.khutaa-media-feature,
html[data-khutaa-theme="dark"] .khutaa-image-gallery-grid .khutaa-media-card,
html[data-khutaa-theme="dark"] .khutaa-image-mosaic .khutaa-media-card,
html[data-khutaa-theme="dark"] .khutaa-image-strip .khutaa-media-card,
html[data-khutaa-theme="dark"] .khutaa-image-contact-sheet .khutaa-media-rank,
html[data-khutaa-theme="dark"] /* الفيديو — مسرح وشبكات وقوائم داكنة مستقلة. */
.khutaa-video-theater,
html[data-khutaa-theme="dark"] .khutaa-video-theater-list .khutaa-media-card,
html[data-khutaa-theme="dark"] .khutaa-video-grid .khutaa-media-card,
html[data-khutaa-theme="dark"] .khutaa-video-filmrail .khutaa-media-card,
html[data-khutaa-theme="dark"] .khutaa-video-premieres .khutaa-media-feature,
html[data-khutaa-theme="dark"] .khutaa-video-playlist .khutaa-media-card,
html[data-khutaa-theme="dark"] .khutaa-audio-studio>.khutaa-media-feature,
html[data-khutaa-theme="dark"] .khutaa-audio-episodes .khutaa-media-card,
html[data-khutaa-theme="dark"] .khutaa-audio-podcast-grid .khutaa-media-card,
html[data-khutaa-theme="dark"] .khutaa-audio-wave-list .khutaa-media-card,
html[data-khutaa-theme="dark"] .khutaa-audio-radio,
html[data-khutaa-theme="dark"] .khutaa-audio-radio-grid .khutaa-media-card,
html[data-khutaa-theme="dark"] .khutaa-audio-playlist .khutaa-media-card,
html[data-khutaa-theme="dark"] .khutaa-media-hub-grid,
html[data-khutaa-theme="dark"] .khutaa-media-hub-panel,
html[data-khutaa-theme="dark"] .khutaa-media-hub-feature,
html[data-khutaa-theme="dark"] .khutaa-media-hub-feature-play,
html[data-khutaa-theme="dark"] .khutaa-media-hub-thumb>span,
html[data-khutaa-theme="dark"] .khutaa-media-hub-audio-feature,
html[data-khutaa-theme="dark"] .khutaa-media-hub-image-arrow,
html[data-khutaa-theme="dark"] .khutaa-media-hub-image-arrow:hover,
html[data-khutaa-theme="dark"] .khutaa-media-hub-image-arrow:focus-visible,
html[data-khutaa-theme="dark"] .khutaa-col2-headlines,
html[data-khutaa-theme="dark"] .khutaa-col3-links,
html[data-khutaa-theme="dark"] .khutaa-col3-headlines{color:var(--kh-dark-text)!important;background-color:var(--kh-dark-card)!important;border-color:var(--kh-dark-border)!important}

/* Generated explicit-white component overrides */
html[data-khutaa-theme="dark"] .khutaa-ranked-list .khutaa-news-card.is-ranked>.alk-card__content,
html[data-khutaa-theme="dark"] .khutaa-builder-sidebar-slot .alk-widget{color:var(--kh-dark-text)!important;background-color:var(--kh-dark-card)!important;border-color:var(--kh-dark-border)!important}


/* Compatibility bridge — KHUTAA Core 3.3.1 */
.khutaa-theme-bridge-stage {
	display: contents;
}

.khutaa-theme-toggle.is-compat-bridge {
	z-index: 99990;
}

.khutaa-theme-toggle.is-compat-bridge.is-bridge-pending,
.khutaa-theme-toggle.is-compat-bridge.is-placement-fallback {
	position: fixed;
	top: 46%;
	right: 16px;
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
}

.khutaa-theme-toggle.is-compat-bridge.is-floating-left {
	right: auto;
	left: 16px;
}

.khutaa-theme-placement-slot {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	min-width: 0;
	min-height: 0;
	list-style: none;
}

.khutaa-theme-placement-slot > .khutaa-theme-toggle {
	margin-inline: 4px;
}

.khutaa-theme-toggle.is-placement-fallback::after {
	content: "";
	position: absolute;
	inset: -5px;
	border: 1px dashed rgba(79,156,255,.45);
	border-radius: inherit;
	pointer-events: none;
}

@media (min-width: 783px) {
	.khutaa-theme-toggle--mobile.is-compat-bridge {
		display: none !important;
	}
}

@media (max-width: 782px) {
	.khutaa-theme-toggle--desktop.is-compat-bridge {
		display: none !important;
	}

	.khutaa-theme-toggle.is-compat-bridge.is-bridge-pending,
	.khutaa-theme-toggle.is-compat-bridge.is-placement-fallback {
		top: auto;
		right: 12px;
		bottom: calc(92px + env(safe-area-inset-bottom, 0px));
	}

	.khutaa-theme-toggle.is-compat-bridge.is-floating-left {
		right: auto;
		left: 12px;
	}

	.khutaa-theme-placement-slot.is-live,
	.khutaa-theme-placement-slot.is-search,
	.khutaa-theme-placement-slot.is-menu-button {
		display: inline-flex;
	}

	.khutaa-theme-toggle.is-mobile-nav-position {
		flex: 1 1 0;
		width: 100%;
		min-width: 0;
		height: 100%;
	}
}

/* KHUTAA Core 3.3.2 — explicit dark coverage for header rows */
html[data-khutaa-theme="dark"] :where(
	.khutaa-v2-brand-row,
	.khutaa-v2-brand-inner,
	.khutaa-v2-main-nav,
	.khutaa-v2-header-shell,
	.khutaa-v2-header-actions
){
	background-color:var(--kh-dark-header)!important;
	border-color:var(--kh-dark-border)!important;
	color:var(--kh-dark-text)!important;
}


/* KHUTAA Core 3.3.3 — page-gap and viewport-edge fix */
html,
body {
	margin: 0;
	padding: 0;
}

html[data-khutaa-theme="dark"],
html[data-khutaa-theme="dark"] body,
html[data-khutaa-theme="dark"] #page,
html[data-khutaa-theme="dark"] .background-overlay,
html[data-khutaa-theme="dark"] .site,
html[data-khutaa-theme="dark"] .site-content,
html[data-khutaa-theme="dark"] .content-area,
html[data-khutaa-theme="dark"] main {
	background-color: var(--kh-dark-bg) !important;
}

html[data-khutaa-theme="dark"] :where(
	.khutaa-v2-header,
	.khutaa-v2-brand-row,
	.khutaa-v2-brand-inner,
	.khutaa-v2-header-actions,
	.khutaa-v2-main-nav,
	.khutaa-v2-main-nav-inner
) {
	background-color: var(--kh-dark-header) !important;
	border-color: var(--kh-dark-border) !important;
}

.khutaa-v2-header {
	width: 100% !important;
	max-width: 100% !important;
	margin-inline: 0 !important;
}


/* Integrated theme-mode controls (1.8.0) */
/* AlKhutaa Pro 1.6.0 — one theme-mode control */
.khutaa-theme-toggle {
  display: inline-flex;
  width: var(--kh-theme-button-size, 40px);
  min-width: var(--kh-theme-button-size, 40px);
  height: var(--kh-theme-button-size, 40px);
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0;
  border: 1px solid var(--kh-theme-button-border, #d0d5dd);
  border-radius: var(--kh-theme-button-radius, 999px);
  background: var(--kh-theme-button-bg, #fff);
  color: var(--kh-theme-button-color, #101828);
  cursor: pointer;
}

.khutaa-theme-toggle.has-label {
  width: auto;
  padding-inline: 12px;
}

.khutaa-theme-toggle__icon {
  display: inline-grid;
  width: 19px;
  height: 19px;
  place-items: center;
}

.khutaa-theme-toggle__icon svg {
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Explicit icon states override older theme CSS and prevent an empty button. */
html:not([data-khutaa-theme="dark"]) .khutaa-theme-toggle__icon--sun {
  display: inline-grid !important;
  visibility: visible !important;
  opacity: 1 !important;
}

html:not([data-khutaa-theme="dark"]) .khutaa-theme-toggle__icon--moon,
html[data-khutaa-theme="dark"] .khutaa-theme-toggle__icon--sun {
  display: none !important;
}

html[data-khutaa-theme="dark"] .khutaa-theme-toggle__icon--moon {
  display: inline-grid !important;
  visibility: visible !important;
  opacity: 1 !important;
}

.khutaa-theme-toggle__icon svg,
.khutaa-theme-toggle__icon svg * {
  visibility: visible !important;
  opacity: 1 !important;
}

.khutaa-mobile-theme-switch {
  display: inline-grid;
  min-height: 44px;
  grid-template-columns: minmax(38px, auto) 50px minmax(38px, auto);
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 5px 9px;
  border: 1px solid var(--alk-mm-border, var(--kh-theme-button-border, #d0d5dd));
  border-radius: 999px;
  background: var(--alk-mm-surface, var(--kh-theme-button-bg, #fff));
  color: var(--alk-mm-text, var(--kh-theme-button-color, #101828));
  font-family: inherit;
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
  touch-action: manipulation;
  pointer-events: auto;
  -webkit-tap-highlight-color: transparent;
}

.khutaa-mobile-theme-switch__label {
  color: inherit !important;
  opacity: 1 !important;
  white-space: nowrap;
}

.khutaa-mobile-theme-switch__track {
  position: relative;
  display: block;
  width: 50px;
  height: 26px;
  border-radius: 999px;
  background: #d9e1ea;
  transition: background .2s ease;
}

.khutaa-mobile-theme-switch__track i {
  position: absolute;
  top: 3px;
  right: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 6px rgba(15, 23, 42, .22);
  transition: transform .22s ease;
}

.khutaa-mobile-theme-switch.is-dark .khutaa-mobile-theme-switch__track {
  background: var(--alk-mm-accent, var(--kh-dark-accent, #4f9cff));
}

.khutaa-mobile-theme-switch.is-dark .khutaa-mobile-theme-switch__track i {
  transform: translateX(-24px);
}

html[data-khutaa-theme="dark"] .khutaa-theme-toggle {
  border-color: var(--kh-dark-border, #303947);
  background: var(--kh-dark-card, #171c24);
  color: var(--kh-dark-text, #f4f6f8);
}

html[data-khutaa-theme="dark"] .khutaa-mobile-theme-switch {
  border-color: var(--alk-mm-border, var(--kh-dark-border, #303947));
  background: var(--alk-mm-surface, var(--kh-dark-surface, #171c24));
  color: var(--alk-mm-text, var(--kh-dark-text, #f4f6f8));
}

