/* Full material pages, including the editor UI mounted by DLE after page load. */
html[data-theme="dark"] .article-page .article-accordion > summary::after,
html[data-theme="dark"] .article-page .file-install-steps > li::before {
  background: var(--ui-tint);
  border-color: var(--ui-line);
  color: var(--ui-accent);
}

html[data-theme="dark"] .modern-site .cs-category-tree .cs-category-tree__branch > summary .cs-category-tree__count,
html[data-theme="dark"] .modern-site .cs-category-tree .cs-category-tree__link .cs-category-tree__count {
  background: var(--ui-soft);
  border-color: var(--ui-line);
  color: var(--ui-muted);
}
html[data-theme="dark"] .modern-site .cs-popular-card .cs-popular-card__image {
  background: var(--ui-soft) !important;
}
html[data-theme="dark"] .article-page .cs-related-card .material-tools { border-color: var(--ui-line); }
html[data-theme="dark"] .article-page .cs-related-card .material-stats,
html[data-theme="dark"] .article-page .cs-related-card .material-stats :is(a,svg) { color: var(--ui-muted) !important; }
html[data-theme="dark"] .article-comments .cs16-captcha__image img { filter: invert(1) grayscale(.5); }

html[data-theme="dark"] .article-comments .tox-tinymce {
  background: var(--ui-surface);
  border-color: var(--ui-line);
}
html[data-theme="dark"] .article-comments .tox :is(.tox-editor-header,.tox-toolbar-overlord,.tox-toolbar,.tox-toolbar__primary,.tox-toolbar__overflow,.tox-menubar,.tox-statusbar) {
  background: var(--ui-raised);
  color: var(--ui-ink);
  border-color: var(--ui-line);
  box-shadow: none;
}
html[data-theme="dark"] .article-comments .tox :is(.tox-edit-area,.tox-edit-area__iframe) {
  background: var(--ui-surface);
  border-color: var(--ui-line);
}
html[data-theme="dark"] .tox :is(.tox-toolbar__group,.tox-statusbar__path-item,.tox-statusbar__wordcount,.tox-statusbar__branding a,.tox-statusbar__resize-handle) {
  color: var(--ui-muted);
  border-color: var(--ui-line);
}
html[data-theme="dark"] .tox :is(.tox-tbtn,.tox-mbtn,.tox-split-button) {
  color: var(--ui-ink);
  background: transparent;
}
html[data-theme="dark"] .tox :is(.tox-tbtn,.tox-mbtn,.tox-statusbar__resize-handle) svg { fill: currentColor; }
html[data-theme="dark"] .tox :is(.tox-tbtn--disabled,.tox-tbtn:disabled) { opacity: .55; }
html[data-theme="dark"] .tox :is(.tox-tbtn,.tox-mbtn):is(:hover,:focus-visible,[aria-pressed="true"],[aria-expanded="true"]),
html[data-theme="dark"] .tox :is(.tox-tbtn--enabled,.tox-tbtn--enabled:hover,.tox-mbtn--active) {
  background: var(--ui-tint);
  color: var(--ui-accent);
}
html[data-theme="dark"] .tox :is(.tox-menu,.tox-collection,.tox-collection__group,.tox-dialog,.tox-dialog__header,.tox-dialog__body,.tox-dialog__footer,.tox-pop__dialog,.tox-insert-table-picker) {
  background: var(--ui-raised);
  border-color: var(--ui-line);
  color: var(--ui-ink);
}
html[data-theme="dark"] .tox :is(.tox-collection__item,.tox-collection__item-label,.tox-dialog__title,.tox-label,.tox-checkbox__label,.tox-button--icon) {
  color: var(--ui-ink);
}
html[data-theme="dark"] .tox .tox-collection .tox-collection__item:is(.tox-collection__item--active,.tox-collection__item--enabled),
html[data-theme="dark"] .tox :is(.tox-listboxfield .tox-listbox--select,.tox-textfield,.tox-textarea,.tox-toolbar-textfield) {
  background: var(--ui-soft);
  border-color: var(--ui-line);
  color: var(--ui-ink);
}
