/* Цвета Quantum (quantum-front colors.scss): акцент #056e62, #00b6a1 */

/* Базовый бренд-цвет темы — используется в кнопках, ссылках, логотипе */
:root,
.g-root {
  --g-color-base-brand: #056e62;
  --g-color-base-brand-hover: #04584e;
  --g-color-base-generic-accent: #056e62;
  --g-color-text-brand-contrast: #fff;
}

/* Кнопка/блок с логотипом «Quantum docs» в сайдбаре (Gravity UI view_action) */
.g-button_view_action,
.g-button_view_action::before {
  --g-button-background-color: #056e62 !important;
  --g-button-background-color-hover: #04584e !important;
  --g-button-text-color: #fff !important;
}
.g-button_view_action {
  background-color: #056e62 !important;
  color: #fff !important;
}

/* Верхний блок TOC: в светлой теме — тёмный текст; в тёмной — светлый (иначе не читается) */
.g-root_theme_light .dc-toc__top,
.g-root_theme_light .dc-toc__top a,
.g-root_theme_light .dc-toc__top .dc-toc__top-header,
.g-root_theme_light .dc-toc__top .dc-toc__top-header_link,
.g-root_theme_light .dc-toc__top .dc-toc__top-main-link,
.g-root_theme_light .dc-toc__top a:first-child {
  color: #0d0d0d !important;
  background-color: transparent !important;
}
.g-root_theme_light .dc-toc__top a:first-child:hover {
  color: #0d0d0d !important;
}

/* Тёмная тема: светлый текст в сайдбаре и контенте для читаемости */
.g-root_theme_dark .dc-toc__top,
.g-root_theme_dark .dc-toc__top a,
.g-root_theme_dark .dc-toc__top .dc-toc__top-header,
.g-root_theme_dark .dc-toc__top .dc-toc__top-header_link,
.g-root_theme_dark .dc-toc__top .dc-toc__top-main-link {
  color: #e6e6e6 !important;
  background-color: transparent !important;
}
.g-root_theme_dark .dc-toc__top a:hover,
.g-root_theme_dark .dc-toc__top a:first-child:hover {
  color: #fff !important;
}
.g-root_theme_dark .dc-doc-page,
.g-root_theme_dark .dc-doc-page__content,
.g-root_theme_dark [class*="DocPage"],
.g-root_theme_dark .yfm-content {
  color: #e6e6e6 !important;
}
.g-root_theme_dark .yfm-content p,
.g-root_theme_dark .yfm-content li,
.g-root_theme_dark .yfm-content td,
.g-root_theme_dark .yfm-content th,
.g-root_theme_dark .yfm-content h1,
.g-root_theme_dark .yfm-content h2,
.g-root_theme_dark .yfm-content h3 {
  color: #e6e6e6 !important;
}
.g-root_theme_dark .yfm-content a {
  color: #00b6a1 !important;
}

/* Главная: заголовки карточек разделов (Введение, Начало работы, Функционал) в тёмной теме — светлый текст */
.g-root_theme_dark [class*="dc-doc-page"] a,
.g-root_theme_dark [class*="DocPage"] a,
.g-root_theme_dark [class*="link"] h2,
.g-root_theme_dark [class*="link"] h3,
.g-root_theme_dark [class*="card"] h2,
.g-root_theme_dark [class*="card"] h3,
.g-root_theme_dark .dc-doc-page__content h2,
.g-root_theme_dark .dc-doc-page__content h3,
.g-root_theme_dark .dc-doc-page__content [class*="title"],
.g-root_theme_dark .dc-doc-page__content [class*="link"] {
  color: #e6e6e6 !important;
}
.g-root_theme_dark .dc-doc-page__content a:hover,
.g-root_theme_dark [class*="DocPage"] a:hover {
  color: #00b6a1 !important;
}

/* Контейнер логотипа в шапке — без фона, логотип уже содержит нужные цвета */
.pc-logo,
a[class*="pc-logo"],
.pc-logo_icon {
  background-color: transparent !important;
}
