
/* Site Command Enterprise v5.0.0.4.3
   Global Enterprise Shell — Production Tracking is the master standard. */

#appShell[data-sc-shell-version="5.0.0.4.3"] {
  min-height: 100vh;
  --sc-shell-sidebar-width: 268px;
  --sc-shell-sidebar-collapsed-width: 78px;
  --sc-shell-header-height: 70px;
  --sc-shell-bg: #0b1424;
  --sc-shell-panel: #101a2b;
  --sc-shell-border: #29384e;
  --sc-shell-text: #f7f9fc;
  --sc-shell-muted: #9fb0c8;
  --sc-shell-accent: #ff6a00;
}

/* Authoritative sidebar geometry */
#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar {
  width: var(--sc-shell-sidebar-width) !important;
  min-width: var(--sc-shell-sidebar-width) !important;
  height: 100vh !important;
  position: fixed !important;
  inset: 0 auto 0 0 !important;
  z-index: 1040 !important;
  display: flex !important;
  flex-direction: column !important;
  overflow: visible !important;
  background: #101823 !important;
  border-right: 1px solid var(--sc-shell-border) !important;
  color: var(--sc-shell-text) !important;
  scrollbar-width: thin;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-brand {
  min-height: 82px !important;
  height: 82px !important;
  flex: 0 0 82px !important;
  display: flex !important;
  align-items: center !important;
  border-bottom: 1px solid var(--sc-shell-border) !important;
  background: #111a2a !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-brand-inner {
  width: 100% !important;
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
  padding: 0 16px !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .brand-mark {
  width: 38px !important;
  height: 38px !important;
  min-width: 38px !important;
  border-radius: 11px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  background: linear-gradient(135deg, #ff7a1a, #ff3b30) !important;
  color: #fff !important;
  font-weight: 900 !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .brand-word {
  color: #fff !important;
  font-weight: 800 !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-collapse-toggle {
  margin-left: auto !important;
  width: 36px !important;
  height: 36px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  border: 1px solid #344259 !important;
  border-radius: 9px !important;
  background: #172233 !important;
  color: #fff !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-nav {
  flex: 1 1 auto !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  padding: 12px 10px 24px !important;
  background: #101823 !important;
}

/* Authoritative group style */
#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-group {
  margin: 0 0 3px !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-group-toggle {
  width: 100% !important;
  min-height: 42px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  padding: 9px 9px !important;
  border: 0 !important;
  border-radius: 8px !important;
  background: transparent !important;
  color: #f4f6fa !important;
  font-size: .74rem !important;
  font-weight: 900 !important;
  letter-spacing: .025em !important;
  text-align: left !important;
  box-shadow: none !important;
  appearance: none !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-group-toggle > span {
  min-width: 0 !important;
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-group-toggle:hover,
#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-group-toggle:focus-visible {
  background: rgba(255,255,255,.055) !important;
  color: #fff !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-group-chevron {
  color: #9eb0c7 !important;
  transition: transform .18s ease !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-group.open .sidebar-group-chevron {
  transform: rotate(180deg) !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-group-items {
  display: none !important;
  padding: 2px 0 5px !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-group.open .sidebar-group-items {
  display: block !important;
}

/* Authoritative link style */
#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-nav-link {
  position: relative !important;
  min-height: 43px !important;
  width: 100% !important;
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
  margin: 2px 0 !important;
  padding: 9px 12px !important;
  border: 0 !important;
  border-left: 3px solid transparent !important;
  border-radius: 10px !important;
  background: transparent !important;
  color: #edf2f8 !important;
  font-size: .96rem !important;
  font-weight: 500 !important;
  line-height: 1.15 !important;
  text-decoration: none !important;
  white-space: nowrap !important;
  box-shadow: none !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-nav-link:hover,
#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-nav-link:focus-visible {
  background: rgba(255,255,255,.065) !important;
  color: #fff !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-nav-link.active {
  background: rgba(255,106,0,.16) !important;
  color: var(--sc-shell-accent) !important;
  border-left-color: var(--sc-shell-accent) !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-nav-icon {
  width: 20px !important;
  min-width: 20px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  color: #b9d4f8 !important;
  font-size: 1rem !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-nav-link.active .sidebar-nav-icon {
  color: var(--sc-shell-accent) !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-nav-text {
  min-width: 0 !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}

/* Authoritative main shell and header */
#appShell[data-sc-shell-version="5.0.0.4.3"] .main-wrap {
  min-height: 100vh !important;
  margin-left: var(--sc-shell-sidebar-width) !important;
  width: calc(100% - var(--sc-shell-sidebar-width)) !important;
  background: var(--sc-shell-bg) !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .topbar {
  min-height: var(--sc-shell-header-height) !important;
  height: var(--sc-shell-header-height) !important;
  padding: 8px 16px 8px 20px !important;
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
  position: sticky !important;
  top: 0 !important;
  z-index: 1030 !important;
  background: #0f1929 !important;
  border-bottom: 1px solid var(--sc-shell-border) !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .topbar-project-identity {
  min-width: 220px !important;
  max-width: 410px !important;
  overflow: hidden !important;
  line-height: 1.2 !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .topbar-project-name {
  color: #fff !important;
  font-size: 1rem !important;
  font-weight: 800 !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .topbar-project-location {
  margin-top: 3px !important;
  color: #a9bad1 !important;
  font-size: .78rem !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .topbar-actions {
  margin-left: auto !important;
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .topbar-project-context {
  min-width: 255px !important;
  max-width: 320px !important;
  min-height: 50px !important;
  margin: 0 !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .account-menu-btn {
  min-height: 50px !important;
}

#appShell[data-sc-shell-version="5.0.0.4.3"] .content {
  width: 100% !important;
  min-width: 0 !important;
}

/* Collapsed state */
body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar {
  width: var(--sc-shell-sidebar-collapsed-width) !important;
  min-width: var(--sc-shell-sidebar-collapsed-width) !important;
}

body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .main-wrap {
  margin-left: var(--sc-shell-sidebar-collapsed-width) !important;
  width: calc(100% - var(--sc-shell-sidebar-collapsed-width)) !important;
}

body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-brand-copy,
body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .brand-mark,
body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-group-label,
body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-group-chevron,
body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-nav-text,
body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-lock-icon {
  display: none !important;
}

body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-brand-inner {
  justify-content: center !important;
  padding-inline: 8px !important;
}

body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-collapse-toggle {
  margin-left: 0 !important;
}

body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-nav {
  overflow: visible !important;
  padding-inline: 9px !important;
}

body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-group-toggle,
body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-nav-link {
  width: 56px !important;
  min-width: 56px !important;
  justify-content: center !important;
  padding: 10px !important;
  margin-inline: auto !important;
}

body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-group-items {
  padding: 2px 0 5px !important;
}

/* Accessible hover/focus labels for every collapsed navigation icon. */
body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-nav-link::after,
body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-group-toggle::after,
body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-collapse-toggle::after {
  content: attr(data-label);
  position: fixed;
  left: var(--sc-tooltip-left, 86px);
  top: var(--sc-tooltip-top, 50%);
  z-index: 1200;
  display: block;
  width: max-content;
  max-width: 260px;
  padding: 8px 11px;
  border: 1px solid #3a4a62;
  border-left: 3px solid var(--sc-shell-accent);
  border-radius: 7px;
  background: #111b2b;
  color: #fff;
  font-size: .82rem;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  box-shadow: 0 10px 25px rgba(0,0,0,.35);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translate(-5px, -50%);
  transition: opacity .14s ease, transform .14s ease, visibility .14s ease;
}

body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-nav-link:hover::after,
body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-nav-link:focus-visible::after,
body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-group-toggle:hover::after,
body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-group-toggle:focus-visible::after,
body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-collapse-toggle:hover::after,
body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar-collapse-toggle:focus-visible::after {
  opacity: 1;
  visibility: visible;
  transform: translate(0, -50%);
}

/* Mobile */
@media (max-width: 991.98px) {
  #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar,
  body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar {
    width: var(--sc-shell-sidebar-width) !important;
    min-width: var(--sc-shell-sidebar-width) !important;
    transform: translateX(-100%) !important;
    transition: transform .2s ease !important;
  }

  #appShell[data-sc-shell-version="5.0.0.4.3"] .sidebar.open {
    transform: translateX(0) !important;
  }

  #appShell[data-sc-shell-version="5.0.0.4.3"] .main-wrap,
  body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] .main-wrap {
    margin-left: 0 !important;
    width: 100% !important;
  }

  #appShell[data-sc-shell-version="5.0.0.4.3"] .topbar {
    min-height: 68px !important;
    height: auto !important;
  }
}

@media (max-width: 767.98px) {
  #appShell[data-sc-shell-version="5.0.0.4.3"] .topbar-project-identity {
    min-width: 0 !important;
    flex: 1 1 auto !important;
  }

  #appShell[data-sc-shell-version="5.0.0.4.3"] .topbar-project-context {
    display: none !important;
  }

  #appShell[data-sc-shell-version="5.0.0.4.3"] .topbar-actions {
    gap: 7px !important;
  }
}


/* Tooltip alignment correction: all group labels and nested links use the
   hovered/focused element's actual viewport position. */
body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"] 
:is(.sidebar-nav-link, .sidebar-group-toggle, .sidebar-collapse-toggle)[data-label]::after {
  inset-inline-start: var(--sc-tooltip-left, 86px) !important;
  inset-block-start: var(--sc-tooltip-top, 50%) !important;
  margin: 0 !important;
}

body.sidebar-collapsed #appShell[data-sc-shell-version="5.0.0.4.3"]
.sidebar-group-items .sidebar-nav-link::after {
  left: var(--sc-tooltip-left, 86px) !important;
  top: var(--sc-tooltip-top, 50%) !important;
}
