/* Hey Xi'an dark mode (ported from the Chengdu Expat theme, recoloured to the sage brand). Driven by html[data-theme="dark"]. */
@media only screen and (max-width: 900px) {
}
html[data-theme="dark"] body {
	background-color: #121212 !important;
	color: #d8d8dc !important;
}
and a plain .navbar
 * rule was giving it a solid dark background too: an ugly floating black
 * box sitting on top of the red bar instead of blending with it like Login/
 * Add Place/Add Event's text already does.
 */
html[data-theme="dark"] .navbar-light {
	background-color: #161a1a !important;
}
html[data-theme="dark"] .navbar-brand.custom-logo-link {
	background: #fff;
	padding: 6px 10px;
	border-radius: 8px;
	display: inline-block;
}
html[data-theme="dark"] .bg-color-alt:nth-of-type(odd) {
	background: #161616 !important;
}
html[data-theme="dark"] .bg-color-alt:nth-of-type(odd) .categories-list {
	background: #1e1e1e !important;
}
html[data-theme="dark"] .sidebar-content {
	background-color: #121212 !important;
}
html[data-theme="dark"] .wrapper .site-main {
	background-color: #121212 !important;
}
html[data-theme="dark"] .navbar-light .navbar-nav .nav-link,
html[data-theme="dark"] .navbar-light .navbar-brand,
html[data-theme="dark"] .navbar-light .navbar-nav .nav-link.dropdown-toggle {
	color: #d8d8dc !important;
}
html[data-theme="dark"] .dropdown-menu {
	background-color: #1e1e1e !important;
	border-color: rgba(255, 255, 255, 0.1) !important;
}
html[data-theme="dark"] .dropdown-item {
	color: #d8d8dc !important;
}
html[data-theme="dark"] .dropdown-item:hover,
html[data-theme="dark"] .dropdown-item:focus {
	background-color: #2a2a2a !important;
	color: #fff !important;
}
html[data-theme="dark"] .card,
html[data-theme="dark"] .card.card-blog,
html[data-theme="dark"] .card.card-blog.card-featured {
	background-color: #121212 !important;
	color: #d8d8dc !important;
	box-shadow: none !important;
	border: none !important;
}
html[data-theme="dark"] .widget-area .card:not(.card-blog),
html[data-theme="dark"] .widget-area .sidebar-widget {
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4) !important;
}
html[data-theme="dark"] .card.card-blog {
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4) !important;
}
html[data-theme="dark"] .card.card-blog:hover {
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6) !important;
}
html[data-theme="dark"] .entry-title a,
html[data-theme="dark"] .card-title,
html[data-theme="dark"] .card-title a,
html[data-theme="dark"] h1,
html[data-theme="dark"] h2,
html[data-theme="dark"] h3,
html[data-theme="dark"] h4,
html[data-theme="dark"] h5,
html[data-theme="dark"] h6 {
	color: #f0f0f2 !important;
}
html[data-theme="dark"] .card-description,
html[data-theme="dark"] .card-description p,
html[data-theme="dark"] .post-meta-date,
html[data-theme="dark"] .post-meta-comments,
html[data-theme="dark"] .card-comment-count,
html[data-theme="dark"] .pagination-summary-item .page-link {
	color: #a8a8b0 !important;
}
html[data-theme="dark"] .page-header,
html[data-theme="dark"] .hero-section h1,
html[data-theme="dark"] .breadcrumb,
html[data-theme="dark"] .breadcrumb a,
html[data-theme="dark"] .breadcrumb span {
	color: #d8d8dc !important;
}
html[data-theme="dark"] .form-control,
html[data-theme="dark"] #searchform .form-control {
	background-color: #1e1e1e !important;
	color: #d8d8dc !important;
	border-color: rgba(255, 255, 255, 0.15) !important;
}
html[data-theme="dark"] .form-control::placeholder {
	color: #8a8a90 !important;
}
html[data-theme="dark"] #searchform .input-group {
	border-color: rgba(255, 255, 255, 0.15) !important;
}
html[data-theme="dark"] #ajax_search_container input.ajax_s {
	background-color: #1e1e1e !important;
	color: #d8d8dc !important;
}
html[data-theme="dark"] .geodir_post_meta.list-group-item,
html[data-theme="dark"] .list-group-item {
	background-color: #1e1e1e !important;
	border-color: rgba(255, 255, 255, 0.1) !important;
	color: #d8d8dc !important;
}
html[data-theme="dark"] .details-page1 .geodir-tabs .geodir-tabs-content.geodir-tabs-as-list > div,
html[data-theme="dark"] .details-page2 .geodir-tabs .geodir-tabs-content.geodir-tabs-as-list > div {
	background-color: #1e1e1e !important;
	color: #d8d8dc !important;
	border-color: rgba(255, 255, 255, 0.1) !important;
}
html[data-theme="dark"] .leaflet-tile-pane {
	filter: invert(1) hue-rotate(180deg) brightness(0.9) contrast(0.9) saturate(0.8);
}
html[data-theme="dark"] .leaflet-control-zoom a {
	background-color: #1e1e1e !important;
	color: #d8d8dc !important;
	border-color: rgba(255, 255, 255, 0.15) !important;
}
html[data-theme="dark"] .leaflet-control-attribution {
	background-color: rgba(30, 30, 30, 0.8) !important;
	color: #a8a8b0 !important;
}
html[data-theme="dark"] .leaflet-control-attribution a {
	color: #c8c8ce !important;
}
html[data-theme="dark"] .pagination .page-link {
	background-color: #1e1e1e !important;
	border-color: rgba(255, 255, 255, 0.1) !important;
	color: #d8d8dc !important;
}
html[data-theme="dark"] .pagination .page-item.active .page-link {
	background-color: #8fd6bd !important;
	border-color: #8fd6bd !important;
	color: #fff !important;
}
html[data-theme="dark"] .card.card-blog .category a {
	background: #2a2a2a !important;
	color: #c8c8ce !important;
}
html[data-theme="dark"] .card.card-blog .category a:hover {
	background: #2a705a !important;
	color: #fff !important;
}
html[data-theme="dark"] .card.card-blog .category i {
	color: #8fd6bd !important;
}
html[data-theme="dark"] hr,
html[data-theme="dark"] .card-footer,
html[data-theme="dark"] .widget-area .card,
html[data-theme="dark"] .widget-area .sidebar-widget {
	border-color: rgba(255, 255, 255, 0.1) !important;
}
html[data-theme="dark"] a {
	color: #8fd6bd !important; 
}
html[data-theme="dark"] a:hover {
	color: #a9e0cb !important;
}
html[data-theme="dark"] .job_filters {
	background-color: #161a1a !important;
}
html[data-theme="dark"] .job_types {
	background-color: #1e1e1e !important;
}
html[data-theme="dark"] .job_filters input[type="text"],
html[data-theme="dark"] .job_filters input[type="submit"] {
	background-color: #1e1e1e !important;
	color: #d8d8dc !important;
	border-color: rgba(255, 255, 255, 0.15) !important;
}
html[data-theme="dark"] .search-results-count {
	color: #a8a8b0 !important;
}
html[data-theme="dark"] .search-type-tabs a {
	background: #2a2a2a !important;
	color: #c8c8ce !important;
}
html[data-theme="dark"] .search-type-tabs a:hover,
html[data-theme="dark"] .search-type-tabs a.active {
	background: #2a705a !important;
	color: #fff !important;
}

/* ---- light / dark / auto toggle (inserted into the top-bar menu and the mobile menu by script) ---- */
.hx-theme-toggle-item { display: flex; align-items: center; list-style: none; }
.hx-theme-toggle {
	display: inline-flex; align-items: center; justify-content: center;
	width: 32px; height: 32px; padding: 0; margin-left: 10px;
	border: 1px solid rgba(255, 255, 255, .55); border-radius: 50%;
	background: transparent; color: #fff; cursor: pointer; line-height: 1;
}
.hx-theme-toggle:hover { background: rgba(255, 255, 255, .18); }
.hx-theme-toggle:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.hx-theme-toggle svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
#nav-topbar .hx-theme-toggle { border-color: #7cbaa5; color: #2a705a; margin: 8px 0 8px 15px; }
html[data-theme="dark"] #nav-topbar .hx-theme-toggle { color: #8fd6bd; }
@media (max-width: 767.98px) { .hx-theme-toggle { width: 44px; height: 44px; } }

/* ---- dark mode: header bar and logo (the brand sage top bar and the logo are unchanged) ---- */
html[data-theme="dark"] .navbar-brand.custom-logo-link img,
html[data-theme="dark"] .custom-logo-link img.custom-logo { background: #fff; padding: 6px 10px; border-radius: 8px; }
html[data-theme="dark"] .navbar-light .navbar-toggler-icon { filter: invert(1); }
html[data-theme="dark"] body.custom-background { background-color: #121212 !important; }
html[data-theme="dark"] .top-bar,
html[data-theme="dark"] .top-bar a { color: #fff; }

/* v2: the header bar carries Bootstrap's .bg-white (!important), so it needs an id-level dark override */
html[data-theme="dark"] #wrapper-navbar .navbar.bg-white,
html[data-theme="dark"] #wrapper-navbar nav.navbar-light { background-color: #161a1a !important; }
html[data-theme="dark"] .top-bar a,
html[data-theme="dark"] .top-bar .nav-link,
html[data-theme="dark"] .top-bar .navbar-nav .nav-link { color: #fff !important; }
html[data-theme="dark"] #wrapper-navbar .navbar-nav .nav-link:hover,
html[data-theme="dark"] #wrapper-navbar .navbar-nav .current-menu-item > .nav-link { color: #8fd6bd !important; }

/* v3: real light-on-dark logo (transparent PNG) instead of the white tile. The header logo link shows the dark-format
   file as a background while the original image stays in place (invisible) to keep the layout and the link. */
html[data-theme="dark"] #wrapper-navbar .navbar-brand.custom-logo-link {
	background: url("images/hx-logo-header-dark.png") no-repeat left center / contain !important;
	padding: 0 !important;
	border-radius: 0 !important;
	box-shadow: none !important;
}
html[data-theme="dark"] #wrapper-navbar .navbar-brand.custom-logo-link img,
html[data-theme="dark"] .custom-logo-link img.custom-logo {
	opacity: 0;
	background: none !important;
	padding: 0 !important;
	border-radius: 0 !important;
}
