/* Left navigation panel from the design proposals.
 *
 * Loaded by both base templates, which sit on different Bootstrap builds
 * (base.html on 5.1.3 from the CDN, base_hr_ui.html on the 5.3 bundle hr-ui
 * compiles). Everything here is therefore written with literal values rather
 * than Bootstrap custom properties, which differ between the two. */

:root {
  --sidebar-width: 244px;
  --sidebar-bg: #16253d;
  --sidebar-text: #cdd7e5;
  --sidebar-muted: #66799a;
  --sidebar-heading: #8fa3bd;
  --sidebar-secondary: #a9b8cc;
}

.app-shell {
  display: flex;
  min-height: 100vh;
  align-items: stretch;
}

.app-main {
  flex: 1;
  min-width: 0;
}

.app-sidebar {
  width: var(--sidebar-width);
  flex: none;
  background: var(--sidebar-bg);
  color: var(--sidebar-text);
  display: flex;
  flex-direction: column;
  padding-bottom: 12px;
}

.app-sidebar__brand {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 16px 16px 10px;
}

.app-sidebar__brand img {
  display: block;
  max-width: 100%;
  height: auto;
}

.app-sidebar__role {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.8px;
  color: #0d1726;
  background: var(--sidebar-heading);
  border-radius: 4px;
  padding: 2px 6px;
  white-space: nowrap;
}

.app-sidebar__nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 2px 12px 10px;
  overflow-y: auto;
}

.app-sidebar__heading {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.4px;
  color: var(--sidebar-muted);
  padding: 8px 8px 3px;
}

.app-sidebar__divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.1);
  margin: 5px 8px;
}

.app-sidebar__link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 10px;
  border-radius: 6px;
  font-size: 13px;
  color: var(--sidebar-text);
  text-decoration: none;
}

.app-sidebar__link:hover,
.app-sidebar__link:focus {
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
}

.app-sidebar__link[aria-current="page"] {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  font-weight: 600;
  box-shadow: inset 2px 0 0 #4d8ef5;
}

/* The "VIAC" group sits a step back from the daily-work links above it. */
.app-sidebar__link--secondary {
  font-size: 12.5px;
  color: var(--sidebar-secondary);
}

.app-sidebar__dot {
  width: 6px;
  height: 6px;
  border-radius: 2px;
  background: var(--sidebar-muted);
  flex: none;
}

.app-sidebar__link[aria-current="page"] .app-sidebar__dot {
  background: var(--sidebar-heading);
}

.app-sidebar__link--secondary .app-sidebar__dot {
  background: #4a5a76;
}

.app-sidebar__count {
  margin-left: auto;
  font-size: 12px;
  font-weight: 700;
  border-radius: 999px;
  padding: 1px 7px;
  background: #2563eb;
  color: #fff;
}

.app-sidebar__count--warning {
  background: #f0b100;
  color: #3d2c00;
}

.app-sidebar__count--danger {
  background: #d0342c;
  color: #fff;
}

.app-sidebar__trophy {
  margin-left: auto;
  line-height: 1;
  color: #f0b100;
}

.app-sidebar__external {
  margin-left: auto;
  font-size: 12px;
  color: var(--sidebar-muted);
}

.app-sidebar__foot {
  margin-top: auto;
  padding: 10px 12px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Below `lg` the panel becomes a band above the content, so a narrow screen is
   not left with a 244px column and nowhere to read. */
@media (max-width: 991.98px) {
  .app-shell {
    display: block;
  }

  .app-sidebar {
    width: 100%;
  }

  .app-sidebar__nav {
    max-height: 60vh;
  }
}
