/**
 * NIKARINA — последний файл в <head>, перебивает legacy/localStorage
 * Убирает белый сайдбар и белую полосу у блоков
 */

html[data-nik-theme="1"],
html[data-nik-theme="1"][data-menu-styles="light"],
html[data-nik-theme="1"][data-menu-styles="dark"],
html[data-nik-theme="1"][data-theme-mode="light"],
html[data-nik-theme="1"][data-theme-mode="dark"] {
  --menu-bg: transparent !important;
  --header-bg: rgba(14, 12, 10, 0.72) !important;
  --custom-white: rgba(22, 18, 16, 0.95) !important;
  --default-body-bg-color: #131214 !important;
}

html[data-nik-theme="1"] body {
  background-color: #131214 !important;
}

html[data-nik-theme="1"] body.has-nikarina-video {
  background-color: transparent !important;
}

/* Сайдбар — полупрозрачный, фон видео/картинки просвечивает */
html[data-nik-theme="1"] #sidebar.app-sidebar,
html[data-nik-theme="1"] .app-sidebar {
  --menu-bg: transparent !important;
  background-color: transparent !important;
  background-image:
    radial-gradient(ellipse 120% 65% at 0% 0%, rgba(212, 115, 42, 0.14), transparent 50%),
    linear-gradient(
      180deg,
      rgba(35, 25, 18, 0.72) 0%,
      rgba(28, 22, 16, 0.38) 42%,
      rgba(19, 18, 20, 0.18) 78%,
      rgba(19, 18, 20, 0.08) 100%
    ) !important;
  box-shadow: none !important;
}

html[data-nik-theme="1"] body.has-nikarina-video #sidebar.app-sidebar,
html[data-nik-theme="1"] body.has-nikarina-video .app-sidebar {
  background-image:
    radial-gradient(ellipse 120% 65% at 0% 0%, rgba(212, 115, 42, 0.12), transparent 50%),
    linear-gradient(
      180deg,
      rgba(35, 25, 18, 0.55) 0%,
      rgba(28, 22, 16, 0.28) 45%,
      rgba(19, 18, 20, 0.1) 80%,
      rgba(19, 18, 20, 0.04) 100%
    ) !important;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

html[data-nik-theme="1"] .app-sidebar::before,
html[data-nik-theme="1"] .app-sidebar .main-sidebar::before {
  display: none !important;
  content: none !important;
  background: none !important;
}

html[data-nik-theme="1"] .app-sidebar .main-sidebar-header {
  position: relative !important;
  width: 100% !important;
  inset: auto !important;
  background-color: transparent !important;
  background-image: none !important;
}

html[data-nik-theme="1"] .app-sidebar .main-sidebar,
html[data-nik-theme="1"] .app-sidebar .simplebar-content,
html[data-nik-theme="1"] .app-sidebar .simplebar-content-wrapper,
html[data-nik-theme="1"] .app-sidebar .simplebar-mask {
  background-color: transparent !important;
}

/* Зона блоков — без белого фона и без detached-полосы */
html[data-nik-theme="1"] .page {
  width: 100% !important;
  max-width: none !important;
  margin: 0 !important;
  padding: 0 !important;
  background-color: transparent !important;
}

html[data-nik-theme="1"] .main-content,
html[data-nik-theme="1"] .app-content,
html[data-nik-theme="1"] .container-fluid {
  background-color: transparent !important;
}

@media (min-width: 992px) {
  html[data-nik-theme="1"] .main-content.app-content,
  html[data-nik-theme="1"] .app-content {
    margin-inline-start: 17rem !important;
    padding-inline-start: 0 !important;
  }

  html[data-nik-theme="1"] .app-header {
    padding-inline-start: 17rem !important;
  }

  /* detached/overlay: убрать плавающую белую «карточку» */
  html[data-nik-theme="1"][data-vertical-style="detached"] .app-sidebar,
  html[data-nik-theme="1"][data-vertical-style="overlay"] .app-sidebar {
    inset-inline-start: 0 !important;
    inset-block-start: 0 !important;
    inset-block-end: 0 !important;
    border-radius: 0 !important;
    height: 100% !important;
    margin: 0 !important;
  }

  html[data-nik-theme="1"][data-vertical-style="detached"] .app-sidebar .main-sidebar-header {
    display: flex !important;
  }
}
