/* Структурная оболочка меню: brand / ops (макеты TMP) */

.psr-nav-suppressed {
  display: none !important;
}

.psr-shell-fake-nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 0 8px 10px;
}

.psr-fake-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  min-height: 40px;
  border-radius: 8px;
  color: inherit;
  text-decoration: none !important;
  font-size: 13px;
  font-weight: 500;
  border: 1px solid transparent;
  box-sizing: border-box;
}
.psr-fake-link:hover {
  background: rgba(127, 127, 127, 0.12);
}
.psr-fake-link.is-active {
  font-weight: 600;
}

/* ---- shared chrome ---- */
.psr-shell-chrome { flex-shrink: 0; }
.psr-rail-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 12px;
  margin: -4px -4px 8px;
  border-bottom: 1px solid var(--psr-border, #d5dee8);
}
.psr-rail-mark {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: #0f2747;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 18px;
  flex: none;
}
[data-psr-theme="brand"][data-mantine-color-scheme="dark"] .psr-rail-mark {
  background: #f4511e;
}
.psr-rail-svg { width: 26px; height: 26px; flex: none; }
.psr-rail-brand-text { line-height: 1.15; min-width: 0; }
.psr-rail-brand-text b { display: block; font-size: 14px; letter-spacing: 0.02em; }
.psr-rail-brand-text span { display: block; font-size: 11px; opacity: 0.65; margin-top: 2px; }

.psr-mission-switch {
  display: block;
  margin: 8px 4px 10px;
  padding: 10px;
  border-radius: 3px;
  border: 1px solid var(--psr-border, #2c4a63);
  background: var(--psr-surface-2, #173347);
  color: inherit;
  text-decoration: none !important;
  cursor: pointer;
}
.psr-ms-lbl {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.65;
}
.psr-ms-val {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  margin-top: 3px;
  font-size: 13px;
  font-weight: 600;
}
.psr-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #3ecf8e;
  box-shadow: 0 0 0 3px rgba(62, 207, 142, 0.18);
  flex: none;
}

.psr-nav-group,
.psr-nav-more-sum {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.65;
  padding: 10px 8px 6px;
  font-weight: 600;
  list-style: none;
  cursor: pointer;
  user-select: none;
}
.psr-nav-more-wrap {
  margin-top: 4px;
  border-top: 1px solid var(--psr-border, rgba(0, 0, 0, 0.08));
  padding-top: 4px;
}
.psr-nav-more-wrap > summary::-webkit-details-marker { display: none; }
.psr-nav-reordered {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 0 2px 8px;
}

/* ---- brand shell (code_artifact) ---- */
[data-psr-theme="brand"] .mantine-AppShell-navbar.psr-shell-brand,
[data-psr-theme="brand"] .psr-shell-brand {
  width: 16rem !important;
}
[data-psr-theme="brand"] .psr-shell-brand .psr-nav-reordered a,
[data-psr-theme="brand"] .psr-shell-brand .psr-nav-reordered [class*="_link_"] {
  border-radius: 10px !important;
  margin: 1px 0;
  padding: 10px 12px !important;
}
[data-psr-theme="brand"] .psr-fake-link {
  border-radius: 10px;
  padding: 10px 12px;
}
[data-psr-theme="brand"][data-mantine-color-scheme="light"] .psr-fake-link:hover {
  background: #d2dae6;
}
[data-psr-theme="brand"] .psr-fake-link.is-active {
  background: rgba(226, 74, 28, 0.14);
  color: #0f2747;
  box-shadow: inset 3px 0 0 #e24a1c;
}
[data-psr-theme="brand"][data-mantine-color-scheme="light"] .psr-fake-link.is-active {
  background: #c8d2e0;
}
[data-psr-theme="brand"][data-mantine-color-scheme="dark"] .psr-fake-link.is-active {
  background: #262626;
  color: #fff;
}

[data-psr-theme="ops"] .psr-fake-link {
  border-radius: 3px;
  padding: 9px 10px;
}
[data-psr-theme="ops"] .psr-fake-link:hover {
  background: var(--psr-surface-2, #173347);
  color: var(--psr-text, #eaf1f6);
}
[data-psr-theme="ops"] .psr-fake-link.is-active {
  background: var(--psr-surface-3, #1f4058);
  border-color: var(--psr-border, #2c4a63);
  color: var(--psr-text, #eaf1f6);
}

/* ---- ops shell (pss-admin-design) ---- */
[data-psr-theme="ops"] .mantine-AppShell-navbar,
[data-psr-theme="ops"] .psr-shell-ops {
  width: 216px !important;
  min-width: 216px !important;
  padding: 0 !important;
}
[data-psr-theme="ops"] .psr-shell-ops .psr-nav-reordered a,
[data-psr-theme="ops"] .psr-shell-ops .psr-nav-reordered [class*="_link_"] {
  border-radius: 3px !important;
  border: 1px solid transparent;
  padding: 9px 10px !important;
  font-size: 13px !important;
  font-weight: 500 !important;
  gap: 10px;
}
[data-psr-theme="ops"] .psr-shell-ops .psr-nav-reordered a:hover,
[data-psr-theme="ops"] .psr-shell-ops .psr-nav-reordered [class*="_link_"]:hover {
  background: var(--psr-surface-2, #173347) !important;
  color: var(--psr-text, #eaf1f6) !important;
}
[data-psr-theme="ops"] .psr-shell-ops .psr-nav-reordered a[data-active],
[data-psr-theme="ops"] .psr-shell-ops .psr-nav-reordered [class*="_link_"][data-active] {
  background: var(--psr-surface-3, #1f4058) !important;
  border-color: var(--psr-border, #2c4a63) !important;
  box-shadow: none !important;
}
[data-psr-theme="ops"] .psr-shell-ops .psr-nav-reordered a[data-active] svg,
[data-psr-theme="ops"] .psr-shell-ops .psr-nav-reordered [class*="_link_"][data-active] svg {
  color: var(--psr-amber, #ff8f2e) !important;
}

/* header denser under ops */
[data-psr-theme="ops"] .mantine-AppShell-header {
  height: 52px !important;
  min-height: 52px !important;
}

/* classic: no chrome */
[data-psr-theme="classic"] .psr-shell-chrome { display: none !important; }
