/**
 * TechLine Theme Switch – Dark content surfaces
 * Covers Elementor pages + Theme Builder single posts / TechLog.
 *
 * Text colors: no widget-type overrides (Heading vs Text Editor).
 * Same Elementor global color → same dark value via --e-global-color-* map.
 */

/* —— Theme Builder: Single Post location —— */
html[data-theme="dark"] .elementor-location-single,
html[data-theme="dark"] .elementor-location-archive,
html[data-theme="dark"] .elementor-location-single .e-con.e-parent,
html[data-theme="dark"] .elementor-location-archive .e-con.e-parent {
  background-color: transparent !important;
}

html[data-theme="dark"] .elementor-location-single a:not(.elementor-button),
html[data-theme="dark"] .elementor-widget-theme-post-title a,
html[data-theme="dark"] .elementor-widget-post-info,
html[data-theme="dark"] .elementor-widget-post-info a,
html[data-theme="dark"] .elementor-widget-post-info span,
html[data-theme="dark"] .elementor-post-info__item,
html[data-theme="dark"] .elementor-post-info__terms-list-item {
  color: var(--tl-text-muted, #b0b0b0) !important;
}

/* —— TechLog single template classes —— */
html[data-theme="dark"] #tl-techlog-single,
html[data-theme="dark"] .tl-techlog-single {
  --tl-brand: #238f99;
  --tl-text: #f5f5f5;
  --tl-muted: #b0b0b0;
  --tl-faint: #7a7a7a;
  --tl-border: rgba(255, 255, 255, 0.1);
  background-color: var(--tlts-page-bg, #141414) !important;
  color: var(--tl-text, #f5f5f5) !important;
}

html[data-theme="dark"] .tl-techlog-aside,
html[data-theme="dark"] #tl-techlog-single .tl-techlog-aside {
  background-color: #1e1e1e !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
  color: #f5f5f5 !important;
}

html[data-theme="dark"] #tl-techlog-single .tl-techlog-content h2,
html[data-theme="dark"] .tl-techlog-content h2,
html[data-theme="dark"] .tl-techlog-content h3 {
  color: #f5f5f5 !important;
}

html[data-theme="dark"] #tl-techlog-single .tl-techlog-content p,
html[data-theme="dark"] #tl-techlog-single .tl-techlog-content li,
html[data-theme="dark"] .tl-techlog-content p,
html[data-theme="dark"] .tl-techlog-content li {
  color: #b0b0b0 !important;
}

/* —— Post cards / loops (TechLog archive) —— */
html[data-theme="dark"] .elementor-posts-container .elementor-post,
html[data-theme="dark"] .elementor-post__card,
html[data-theme="dark"] .e-loop-item,
html[data-theme="dark"] .e-loop-item > .e-con {
  background-color: #1e1e1e !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
  color: #f5f5f5 !important;
}

html[data-theme="dark"] .elementor-post-info,
html[data-theme="dark"] .elementor-post-info a,
html[data-theme="dark"] .elementor-post-info__item {
  color: #7a7a7a !important;
}

html[data-theme="dark"] .elementor-location-single .tl-techlog-single.e-con {
  background-color: #141414 !important;
}

html[data-theme="dark"] .elementor-location-single .tl-techlog-aside.e-con {
  background-color: #1e1e1e !important;
}

/* —— Dividers / borders on single —— */
html[data-theme="dark"] .elementor-location-single .elementor-divider-separator,
html[data-theme="dark"] .elementor-location-single hr {
  border-color: rgba(255, 255, 255, 0.1) !important;
}
