:root {
  --prototype-sidebar-width: 272px;
  --prototype-sidebar-collapsed-width: 88px;
  --prototype-sidebar-bg: #0b1727;
  --prototype-sidebar-muted: #9da9bb;
  --prototype-sidebar-border: rgba(255,255,255,.08);
  --prototype-sidebar-hover: rgba(255,255,255,.06);
  --prototype-sidebar-active: rgba(42, 123, 228, .18);
  --prototype-shell-shadow: 0 .125rem .25rem rgba(0,0,0,.06);
}

body.prototype-shell-enabled {
  min-height: 100vh;
  padding-left: var(--prototype-sidebar-width);
}

.prototype-sidebar {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: var(--prototype-sidebar-width);
  background: var(--prototype-sidebar-bg);
  color: #fff;
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--prototype-sidebar-border);
  z-index: 1040;
}

.prototype-sidebar-header {
  padding: 18px 18px 14px;
  border-bottom: 1px solid var(--prototype-sidebar-border);
}

.prototype-sidebar-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.prototype-sidebar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  text-decoration: none;
}

.prototype-sidebar-brand:hover { color: #fff; }

.prototype-sidebar-collapse {
  width: 32px;
  height: 32px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 10px;
  background: rgba(255,255,255,.06);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  transition: background .15s ease, transform .15s ease;
}

.prototype-sidebar-collapse:hover {
  background: rgba(255,255,255,.12);
}

.prototype-sidebar-brand-mark {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: rgba(42, 123, 228, .2);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
}

.prototype-sidebar-brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.prototype-sidebar-brand-title {
  font-family: 'Poppins', sans-serif;
  font-size: 14px;
  font-weight: 700;
}

.prototype-sidebar-brand-subtitle,
.prototype-sidebar-note {
  color: var(--prototype-sidebar-muted);
  font-size: 11px;
}

.prototype-sidebar-body {
  flex: 1;
  overflow-y: auto;
  padding: 14px 12px 18px;
}

.prototype-nav-section + .prototype-nav-section {
  margin-top: 18px;
}

.prototype-nav-label {
  color: var(--prototype-sidebar-muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  padding: 0 10px;
  margin-bottom: 8px;
}

.prototype-nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.prototype-nav-item {
  margin-bottom: 4px;
}

.prototype-nav-link {
  display: flex;
  align-items: center;
  gap: 10px;
  color: rgba(255,255,255,.92);
  text-decoration: none;
  padding: 10px 12px;
  border-radius: 10px;
  transition: background .15s ease, color .15s ease;
}

.prototype-nav-link:hover {
  background: var(--prototype-sidebar-hover);
  color: #fff;
}

.prototype-nav-link.active {
  background: var(--prototype-sidebar-active);
  color: #fff;
  box-shadow: inset 0 0 0 1px rgba(42, 123, 228, .35);
}

.prototype-nav-icon {
  width: 18px;
  text-align: center;
  opacity: .9;
  flex: 0 0 18px;
}

.prototype-nav-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.prototype-nav-title {
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1.2;
}

.prototype-nav-subtitle {
  color: var(--prototype-sidebar-muted);
  font-size: 10.5px;
  line-height: 1.2;
  margin-top: 2px;
}

.prototype-shell-badge {
  font-size: 10px;
  font-weight: 700;
  color: #f5803e;
  background: rgba(245, 128, 62, .14);
  border: 1px solid rgba(245, 128, 62, .28);
  border-radius: 999px;
  padding: 2px 8px;
}

.prototype-topnav-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-right: 8px;
}

.prototype-topnav-select {
  min-width: 200px;
  height: 32px;
  border-radius: 8px;
  border: 1px solid var(--falcon-gray-300, #d8e2ef);
  background: #fff;
  color: var(--falcon-gray-900, #0b1727);
  font-size: 12px;
  padding: 0 10px;
}

.prototype-topnav-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 32px;
  padding: 0 12px;
  border-radius: 8px;
  border: 1px solid var(--falcon-gray-300, #d8e2ef);
  background: #fff;
  color: var(--falcon-gray-700, #4d5969);
  text-decoration: none;
  font-size: 12px;
  font-weight: 600;
}

.prototype-topnav-btn:hover {
  color: var(--falcon-primary, #2A7BE4);
  border-color: var(--falcon-primary, #2A7BE4);
  background: #f9fafd;
}

.prototype-sidebar-toggle {
  display: none;
  position: fixed;
  right: 16px;
  bottom: 16px;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 999px;
  background: var(--falcon-primary, #2A7BE4);
  color: #fff;
  box-shadow: 0 10px 24px rgba(42, 123, 228, .3);
  z-index: 1050;
}

.prototype-sidebar-backdrop {
  display: none;
}

body.prototype-shell-enabled .topnav {
  box-shadow: var(--prototype-shell-shadow);
}

body.prototype-shell-enabled .page-wrapper {
  max-width: 100%;
}

body.prototype-sidebar-collapsed {
  padding-left: var(--prototype-sidebar-collapsed-width);
}

body.prototype-sidebar-collapsed .prototype-sidebar {
  width: var(--prototype-sidebar-collapsed-width);
}

body.prototype-sidebar-collapsed .prototype-sidebar-brand-text,
body.prototype-sidebar-collapsed .prototype-sidebar-note,
body.prototype-sidebar-collapsed .prototype-nav-label,
body.prototype-sidebar-collapsed .prototype-nav-subtitle,
body.prototype-sidebar-collapsed .prototype-nav-title,
body.prototype-sidebar-collapsed .prototype-shell-badge,
body.prototype-sidebar-collapsed .prototype-sidebar-header .d-flex > span:first-child {
  display: none !important;
}

body.prototype-sidebar-collapsed .prototype-sidebar-header {
  padding-left: 14px;
  padding-right: 14px;
}

body.prototype-sidebar-collapsed .prototype-sidebar-header-row {
  flex-direction: column;
  align-items: center;
}

body.prototype-sidebar-collapsed .prototype-sidebar-brand {
  justify-content: center;
}

body.prototype-sidebar-collapsed .prototype-nav-link {
  justify-content: center;
  padding-left: 10px;
  padding-right: 10px;
}

body.prototype-sidebar-collapsed .prototype-nav-icon {
  margin: 0;
}

body.prototype-sidebar-collapsed .prototype-sidebar-collapse i {
  transform: rotate(180deg);
}

@media (max-width: 991.98px) {
  body.prototype-shell-enabled {
    padding-left: 0;
  }

  .prototype-sidebar {
    width: var(--prototype-sidebar-width);
    transform: translateX(-100%);
    transition: transform .2s ease;
    box-shadow: 0 0 0 rgba(0,0,0,0);
  }

  body.prototype-sidebar-open .prototype-sidebar {
    transform: translateX(0);
    box-shadow: 0 12px 30px rgba(0,0,0,.28);
  }

  .prototype-sidebar-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .prototype-sidebar-collapse {
    display: none;
  }

  .prototype-sidebar-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(11, 23, 39, .45);
    z-index: 1035;
  }

  body.prototype-sidebar-open .prototype-sidebar-backdrop {
    display: block;
  }

  .prototype-topnav-actions {
    width: 100%;
    justify-content: flex-end;
    margin-right: 0;
    margin-top: 8px;
  }

  .prototype-topnav-select {
    min-width: 0;
    width: 100%;
  }

  .topnav {
    height: auto;
    min-height: 56px;
    flex-wrap: wrap;
    padding-top: 10px;
    padding-bottom: 10px;
  }

  .topnav-right {
    width: 100%;
    justify-content: flex-end;
    margin-left: 0 !important;
  }
}
