/* =====================================================
   SIDEBAR – jasny panel po lewej (jak na screenie)
   ===================================================== */
.sidebar{
  position: sticky;
  top: 0;
  height: 100vh;
  background: var(--panel);
  border-right: 1px solid rgba(11, 18, 32, 0.10);
  z-index: 20;
}

.sidebar__inner{
  height: 100%;
  display: flex;
  flex-direction: column;
  padding: 28px 22px;
}

.sidebar__brand{
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 18px;
}

.sidebar__logoRow{
  display: flex;
  align-items: center;
  gap: 10px;
}

.sidebar__wordmark{
  font-weight: 1000;
  letter-spacing: 1px;
  font-size: 30px;
  line-height: 1;
  color: #0b1220;
}

.sidebar__mark{
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 999px;
  background: var(--blue);
  transform: translateY(2px);
  margin-left: 2px;
}

.sidebar__tagline{
  margin-top: 6px;
  max-width: 260px;
  color: rgba(11, 18, 32, 0.70);
  font-weight: 700;
  font-size: 14px;
  line-height: 1.35;
}

.sidebar__nav{
  margin-top: 8px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sidebar__link{
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  font-weight: 900;
  font-size: 14px;

  color: rgba(11, 18, 32, 0.86);
  border: 1px solid rgba(11, 18, 32, 0.10);
  background: rgba(255,255,255,0.70);
  transition: background .12s ease, border-color .12s ease, color .12s ease;
}

.sidebar__icon{
  width: 22px;
  display: inline-flex;
  justify-content: center;
  opacity: 0.9;
}

.sidebar__link:hover{
  border-color: rgba(11, 92, 255, 0.25);
  color: rgba(11, 92, 255, 0.98);
  background: rgba(255,255,255,0.95);
}

.sidebar__link.is-active{
  background: var(--blue);
  border-color: var(--blue);
  color: #ffffff;
}

.sidebar__sep{
  height: 1px;
  background: rgba(11, 18, 32, 0.10);
  margin: 12px 0;
}

/* stopka sidebara (menu użytkownika) */
.sidebar__footer{
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid rgba(11, 18, 32, 0.10);
}

/* =====================================================
   FIX: menu użytkownika w stopce sidebara
   ZAWSZE otwieraj DO GÓRY (desktop)
   ===================================================== */
.sidebar__footer .userbar__menu{
  top: auto !important;
  bottom: calc(100% + 8px) !important;
}

/* =====================================================
   MOBILE
   ===================================================== */
@media (max-width: 980px){
  .sidebar{
    position: relative;
    height: auto;
    border-right: none;
    border-bottom: 1px solid rgba(11, 18, 32, 0.10);
  }

  .sidebar__inner{
    padding: 18px 14px;
  }

  .sidebar__nav{
    flex-direction: row;
    flex-wrap: wrap;
    gap: 10px;
  }

  .sidebar__link{
    width: auto;
  }

  .sidebar__wordmark{
    font-size: 24px;
  }

  /* Na mobile dropdown niech otwiera się normalnie w dół */
  .sidebar__footer .userbar__menu{
    bottom: auto !important;
    top: calc(100% + 8px) !important;
  }
}
