/* LITREVO workspace navigation shell: compact by default, overlay when expanded. */
.ui-reference-light:not(.role-master) {
  --exact-rail-width: 0px;
}

.ui-reference-light:not(.role-master) .app-shell {
  grid-template-columns: 84px minmax(0, 1fr);
}

.ui-reference-light:not(.role-master) .ref-utility-rail {
  display: none !important;
}

.ui-reference-light .sidebar-sublink::before {
  display: none !important;
  content: none !important;
}

.ui-reference-light .sidebar-group-inner {
  margin: 2px 0 6px 17px;
  padding: 2px 0 4px 17px;
  border-left: 0;
}

.ui-reference-light .sidebar-sublink {
  position: relative;
  min-height: 40px;
  margin: 2px 0;
  padding: 9px 10px;
  border-radius: 10px;
}

.ui-reference-light .sidebar-sublink:hover,
.ui-reference-light .sidebar-sublink.active {
  color: var(--primary);
  background: var(--primary-soft);
}

.ui-reference-light:not(.role-master) .sidebar-bottom {
  padding-top: 10px;
}

.ui-reference-light:not(.role-master) .sidebar-logout {
  width: 100%;
  margin: 0;
}

.ui-reference-light .topbar-support-button,
.ui-reference-light .topbar-settings-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  min-width: 46px;
  height: 46px;
  padding: 0;
  color: #47678f;
  border: 1px solid #dde7f4;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 7px 18px rgba(24, 76, 138, .06);
  transition: color .18s ease, border-color .18s ease, background .18s ease, transform .18s ease;
}

.ui-reference-light .topbar-support-button:hover,
.ui-reference-light .topbar-settings-icon:hover,
.ui-reference-light .topbar-support-button.active,
.ui-reference-light .topbar-settings-icon.active {
  color: #fff;
  border-color: transparent;
  background: var(--primary-gradient);
  transform: translateY(-1px);
}

.ui-reference-light .topbar-support-button > .icon,
.ui-reference-light .topbar-settings-icon > .icon {
  width: 21px;
  height: 21px;
}

.ui-reference-light .topbar-avatar-menu .user-menu-trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  min-width: 48px;
  height: 48px;
  padding: 4px;
  border: 1px solid #dce7f5;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 7px 18px rgba(24, 76, 138, .06);
}

.ui-reference-light .topbar-avatar-menu .user-menu-copy,
.ui-reference-light .topbar-avatar-menu .user-menu-trigger > .icon {
  display: none;
}

.ui-reference-light .topbar-avatar-menu .avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
}

@media (min-width: 1081px) {
  body.ui-reference-light:not(.role-master) {
    --sidebar-width: 84px;
  }

  body.ui-reference-light:not(.role-master) .sidebar {
    width: 84px;
    transition: width .22s ease, padding .22s ease, box-shadow .22s ease;
  }

  body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar {
    width: 300px;
    padding: 0 15px 13px;
    box-shadow: 18px 0 46px rgba(23, 56, 104, .16);
  }

  body.ui-reference-light:not(.role-master).sidebar-flyout-open .sidebar {
    z-index: 80;
  }

  body.ui-reference-light:not(.role-master).sidebar-flyout-open .mobile-overlay {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 79;
    background: rgba(10, 31, 62, .24);
    -webkit-backdrop-filter: blur(1.5px);
    backdrop-filter: blur(1.5px);
  }

  body.ui-reference-light:not(.role-master).sidebar-compact .sidebar-bottom {
    display: flex !important;
    align-items: center;
    justify-content: center;
  }

  body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-bottom {
    display: block !important;
  }
}

@media (max-width: 720px) {
  .ui-reference-light .topbar-actions {
    gap: 6px;
  }

  .ui-reference-light .topbar-support-button,
  .ui-reference-light .topbar-settings-icon,
  .ui-reference-light .topbar-avatar-menu .user-menu-trigger {
    width: 42px;
    min-width: 42px;
    height: 42px;
  }

  .ui-reference-light .topbar-avatar-menu .avatar {
    width: 34px;
    height: 34px;
  }
}

/* V2: high-contrast expanded navigation, matching the supplied interaction pattern. */
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar {
  padding: 0 18px 14px;
  color: #17345f;
  background:
    radial-gradient(circle at 93% 32%, rgba(73, 150, 255, .14) 1px, transparent 1.3px) 0 0 / 13px 13px,
    #fff;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar::before {
  display: none;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-head {
  height: 88px;
  min-height: 88px;
  padding: 0 10px;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-brand-full {
  width: 172px;
  max-width: 172px;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-context-card {
  min-height: 84px;
  margin: 4px 1px 17px;
  padding: 13px 15px;
  grid-template-columns: 48px minmax(0, 1fr) 18px;
  gap: 13px;
  border-color: #d7e4f5;
  border-radius: 17px;
  box-shadow: 0 8px 22px rgba(26, 81, 154, .055);
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-context-avatar {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: linear-gradient(145deg, #176af4, #2860ed);
  font-size: 13px;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-context-card strong {
  color: #17345f;
  font-size: 14.5px;
  font-weight: 800;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-context-card small {
  margin-top: 4px;
  color: #7185a8;
  font-size: 11.5px;
  font-weight: 600;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav {
  padding: 0 3px 12px;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .nav-quick-label {
  display: block !important;
  margin: 9px 11px 6px;
  padding-top: 11px;
  border-top: 1px solid #e6edf8;
  color: #667da8;
  font-size: 9.5px;
  font-weight: 850;
  letter-spacing: .1em;
  text-transform: uppercase;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-link,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-group-toggle {
  min-height: 50px;
  margin: 2px 0;
  padding: 0 14px;
  gap: 13px;
  border-radius: 11px;
  color: #355b91;
  background: transparent;
  font-size: 14px;
  font-weight: 720;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-link > .icon,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-group-toggle > .icon {
  width: 20px;
  height: 20px;
  color: #2e69bd;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-premium > .sidebar-link.active {
  color: #fff;
  background: linear-gradient(105deg, #0d63ec 0%, #0d7bf4 62%, #09a8c9 100%);
  box-shadow: 0 10px 24px rgba(13, 101, 235, .22);
  font-weight: 800;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-premium > .sidebar-link.active > .icon {
  color: #fff;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-link.active::before,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-link.active::after,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-group.active > .sidebar-group-toggle::before,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-group.active > .sidebar-group-toggle::after {
  display: none;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-link:hover,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-group-toggle:hover {
  color: #0d64de;
  background: #eef5ff;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-group {
  margin: 3px 0;
  overflow: hidden;
  border: 1px solid transparent;
  border-radius: 12px;
  background: transparent;
  transition: border-color .18s ease, background .18s ease, box-shadow .18s ease;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-group.open {
  border-color: #d9e8fb;
  background: linear-gradient(145deg, #f2f7ff, #eaf5ff);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .8);
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-group.open > .sidebar-group-toggle,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-group.active > .sidebar-group-toggle {
  color: #0d5dcc;
  background: rgba(221, 237, 255, .72);
  font-weight: 800;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-group.open > .sidebar-group-toggle > .icon,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-group.active > .sidebar-group-toggle > .icon,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-group.open .sidebar-group-chevron {
  color: #0d68e8;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-group-inner {
  gap: 1px;
  margin: 0;
  padding: 3px 8px 9px 35px;
  border: 0;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-group.open .sidebar-sublink {
  min-height: 45px;
  margin: 1px 0;
  padding: 8px 10px;
  gap: 11px;
  color: #365d92 !important;
  background: transparent;
  font-size: 13.5px;
  font-weight: 650;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-group.open .sidebar-sublink > .icon {
  width: 17px;
  height: 17px;
  color: #5f82b5;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-group.open .sidebar-sublink:hover {
  color: #0d62d7 !important;
  background: rgba(255, 255, 255, .78);
  transform: none;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-group.open .sidebar-sublink.active {
  color: #075ccc !important;
  background: #fff;
  box-shadow: 0 5px 14px rgba(26, 83, 157, .08);
  font-weight: 800;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-bottom {
  padding: 12px 1px 0;
  border-top: 1px solid #e7edf7;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-logout {
  min-height: 52px;
  padding: 0 16px;
  border-color: #f1d7df;
  border-radius: 12px;
  color: #ce3857;
  background: #fff7f9;
  font-size: 14px;
}

@media (min-width: 1081px) {
  body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar {
    width: 338px;
  }
}

@media (max-width: 1080px) {
  body.ui-reference-light:not(.role-master) .sidebar {
    width: min(338px, calc(100vw - 44px));
  }
}

/* V3: keep every dropdown parent label visible and color-stable in all states. */
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-group-toggle,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-group-toggle:hover,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-group-toggle:focus,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-group-toggle:focus-visible,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-group.open > .sidebar-group-toggle,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-group.active > .sidebar-group-toggle {
  color: #355b91 !important;
  -webkit-text-fill-color: #355b91 !important;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-group-toggle > span:first-of-type,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-group-toggle:hover > span:first-of-type,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-group-toggle:focus > span:first-of-type,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-group.open > .sidebar-group-toggle > span:first-of-type,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-group.active > .sidebar-group-toggle > span:first-of-type {
  display: block !important;
  visibility: visible !important;
  min-width: 0;
  flex: 1 1 auto;
  color: #355b91 !important;
  -webkit-text-fill-color: #355b91 !important;
  opacity: 1 !important;
}

body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-group-toggle > .icon,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-group-toggle:hover > .icon,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-group-toggle:focus > .icon,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-group.open > .sidebar-group-toggle > .icon,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-nav-group.active > .sidebar-group-toggle > .icon,
body.ui-reference-light:not(.role-master):not(.sidebar-compact) .sidebar-group-chevron {
  color: #2e69bd !important;
  opacity: 1 !important;
}

/* V4: keep every header action icon visible in normal and interactive states. */
body.ui-reference-light :is(.notification-button, .topbar-support-button, .topbar-settings-icon) {
  color: #365f98 !important;
  -webkit-text-fill-color: #365f98 !important;
  border-color: #dce7f5 !important;
  background: #fff !important;
}

body.ui-reference-light :is(.notification-button, .topbar-support-button, .topbar-settings-icon):is(:hover, :focus, :focus-visible, .active) {
  color: #0d68e8 !important;
  -webkit-text-fill-color: #0d68e8 !important;
  border-color: #a9c9f7 !important;
  background: #eef6ff !important;
  box-shadow: 0 8px 20px rgba(18, 103, 232, .12) !important;
  transform: translateY(-1px);
}

body.ui-reference-light :is(.notification-button, .topbar-support-button, .topbar-settings-icon) > .icon {
  display: block !important;
  visibility: visible !important;
  color: currentColor !important;
  opacity: 1 !important;
}

body.ui-reference-light .notification-count {
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
}

/* V5: prevent clicked checkboxes from inheriting the text-field focus halo. */
body.ui-reference-light input[type="checkbox"] {
  min-height: 0 !important;
}

body.ui-reference-light input[type="checkbox"]:is(:focus, :focus-visible, :active) {
  outline: 0 !important;
  outline-offset: 0 !important;
  box-shadow: none !important;
}

/* V6: route-independent Contacts column editor, replacing the legacy dropdown. */
body.ui-reference-light .lcx-columns-dialog {
  width: min(730px, calc(100vw - 24px));
  max-width: none;
  max-height: calc(100dvh - 24px);
  margin: auto;
  padding: 0;
  border: 0;
  border-radius: 14px;
  color: #142b4e;
  background: #fff;
  box-shadow: 0 28px 76px rgba(10, 25, 50, .28);
  overflow: hidden;
}

body.ui-reference-light .lcx-columns-dialog::backdrop {
  background: rgba(17, 27, 42, .47);
  backdrop-filter: blur(3px);
}

body.ui-reference-light .lcx-columns-panel {
  max-height: calc(100dvh - 24px);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  background: #fff;
}

body.ui-reference-light .lcx-columns-head {
  min-height: 88px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 16px 25px 16px 34px;
  border-bottom: 1px solid #dfe5ee;
  background: #f7f9fc;
}

body.ui-reference-light .lcx-columns-head h3 {
  display: flex;
  align-items: center;
  gap: 11px;
  margin: 0;
  color: #10192b;
  font-size: 21px;
  font-weight: 800;
  line-height: 1.2;
}

body.ui-reference-light .lcx-columns-hash {
  color: #1467f4;
  font-size: 20px;
  font-weight: 850;
}

body.ui-reference-light .lcx-columns-close {
  width: 38px;
  height: 38px;
  min-height: 38px;
  display: grid;
  place-items: center;
  flex: 0 0 38px;
  padding: 0;
  border: 1px solid #8092af;
  border-radius: 50%;
  color: #506584;
  background: #fff;
  cursor: pointer;
}

body.ui-reference-light .lcx-columns-close:hover {
  color: #0d68e8;
  border-color: #8cb6f3;
  background: #eef6ff;
}

body.ui-reference-light .lcx-columns-close > .icon {
  width: 19px;
  height: 19px;
}

body.ui-reference-light .lcx-columns-body {
  min-height: 0;
  padding: 27px 25px 25px;
  overflow: auto;
  background: #fff;
}

body.ui-reference-light .lcx-columns-intro {
  margin: 0 0 23px;
  color: #687c9d;
  font-size: 14px;
  line-height: 1.55;
}

body.ui-reference-light .lcx-columns-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

body.ui-reference-light .lcx-column-option {
  position: relative;
  min-height: 96px;
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  align-items: center;
  gap: 18px;
  padding: 16px 23px;
  border: 1px solid #cfdaea;
  border-radius: 10px;
  color: #233a5c;
  background: #fff;
  cursor: pointer;
  transition: border-color .16s ease, background .16s ease, box-shadow .16s ease;
}

body.ui-reference-light .lcx-column-option:hover {
  border-color: #8db7f6;
  background: #fbfdff;
  box-shadow: 0 7px 18px rgba(22, 91, 186, .06);
}

body.ui-reference-light .lcx-column-option > input {
  position: absolute;
  width: 1px;
  height: 1px;
  min-height: 0 !important;
  opacity: 0;
  pointer-events: none;
}

body.ui-reference-light .lcx-column-check {
  position: relative;
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border: 2px solid #b9c7db;
  border-radius: 5px;
  background: #fff;
  transition: border-color .16s ease, background .16s ease, box-shadow .16s ease;
}

body.ui-reference-light .lcx-column-option > input:checked + .lcx-column-check {
  border-color: #126bf4;
  background: #126bf4;
  box-shadow: 0 7px 16px rgba(18, 107, 244, .2);
}

body.ui-reference-light .lcx-column-option > input:checked + .lcx-column-check::after {
  content: '';
  width: 17px;
  height: 31px;
  margin-top: -7px;
  border: solid #fff;
  border-width: 0 8px 8px 0;
  transform: rotate(45deg);
}

body.ui-reference-light .lcx-column-name {
  display: block;
  color: #263d60;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.45;
}

body.ui-reference-light .lcx-columns-foot {
  min-height: 87px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 16px;
  padding: 19px 25px;
  border-top: 1px solid #e1e6ee;
  background: #fff;
}

body.ui-reference-light .lcx-columns-foot button {
  height: 49px;
  min-height: 49px;
  padding: 0 24px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
}

body.ui-reference-light .lcx-columns-cancel {
  min-width: 145px;
  border: 0;
  color: #17243b;
  background: #fff;
}

body.ui-reference-light .lcx-columns-done {
  min-width: 233px;
  border: 0;
  color: #fff;
  background: linear-gradient(105deg, #0e64eb, #1478f7);
  box-shadow: 0 9px 20px rgba(18, 104, 239, .18);
}

body.ui-reference-light .lcx-columns-done:hover {
  box-shadow: 0 12px 25px rgba(18, 104, 239, .25);
  transform: translateY(-1px);
}

@media (max-width: 640px) {
  body.ui-reference-light .lcx-columns-dialog {
    width: calc(100vw - 16px);
    max-height: calc(100dvh - 16px);
  }

  body.ui-reference-light .lcx-columns-panel {
    max-height: calc(100dvh - 16px);
  }

  body.ui-reference-light .lcx-columns-head {
    min-height: 76px;
    padding: 13px 16px 13px 20px;
  }

  body.ui-reference-light .lcx-columns-body {
    padding: 20px 16px;
  }

  body.ui-reference-light .lcx-columns-grid {
    grid-template-columns: 1fr;
  }

  body.ui-reference-light .lcx-column-option {
    min-height: 82px;
    grid-template-columns: 50px minmax(0, 1fr);
    gap: 15px;
    padding: 14px 17px;
  }

  body.ui-reference-light .lcx-column-check {
    width: 50px;
    height: 50px;
  }

  body.ui-reference-light .lcx-column-option > input:checked + .lcx-column-check::after {
    width: 14px;
    height: 27px;
    border-width: 0 7px 7px 0;
  }

  body.ui-reference-light .lcx-columns-foot {
    min-height: 76px;
    gap: 10px;
    padding: 13px 16px;
  }

  body.ui-reference-light .lcx-columns-foot button {
    min-width: 0;
  }

  body.ui-reference-light .lcx-columns-cancel {
    flex: 1 1 35%;
  }

  body.ui-reference-light .lcx-columns-done {
    flex: 1 1 65%;
  }
}
