.burger-btn {
  display: flex;
  background: #132328bd;
  border: 1px solid #ffffff22;
  color: #fffe;
  width: 48px;
  height: 48px;
  border-radius: 6px;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
  font-size: 18px;
  flex-shrink: 0;
}
.burger-btn:hover {
  background: #ffffff18;
  border-color: var(--cyan);
  color: var(--cyan);
}
.burger-btn i {
  transition: transform 0.3s ease;
}

.sidebar {
  position: absolute;
  z-index: 25;
  left: 24px;
  top: 80px;
  bottom: 75px;
  display: flex;
  gap: 20px;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.sidebar.collapsed {
  transform: translateX(-120%);
}

.rail {
  width: 48px;
  height: 300px;
  background: #132328e8;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 10px 30px #0004;
  backdrop-filter: blur(8px);
}
.rail-btn {
  width: 48px;
  height: 50px;
  border: 0;
  background: transparent;
  color: #93a3a5;
  cursor: pointer;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}
.rail-btn.active, .rail-btn:hover {
  background: #ffffff12;
  color: #d9e5e5;
}
.rail-btn.active {
  box-shadow: inset 3px 0 var(--cyan);
}

.rail-close-mobile {
  display: none !important;
  background: transparent;
  border: none;
  color: #fff;
  cursor: pointer;
  transition: color 0.2s, background 0.2s;
}
.rail-close-mobile:hover {
  color: var(--cyan);
  background: rgba(255, 255, 255, 0.08);
}

#mainNav {
  width: 150px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-top: 4px;
  max-height: calc(100vh - 160px);
  overflow-y: auto;
  scrollbar-width: none;
}
#mainNav::-webkit-scrollbar {
  display: none;
}
.nav-item {
  border: 0;
  background: none;
  color: #ffffffb3;
  text-align: left;
  padding: 8px 12px;
  border-radius: 4px;
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 21px;
  letter-spacing: .5px;
  cursor: pointer;
  text-shadow: 0 2px 10px #0008;
  white-space: nowrap;
  transition: .18s;
  width: fit-content; 
  display: block;
}
.nav-item:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.05);
  transform: translateX(5px);
}
.nav-item.active {
  color: #fff;
  background: rgba(114, 242, 233, 0.12);
  border-left: 4px solid var(--cyan);
  font-size: 23px;
  padding-right: 18px;
}
.nav-item.muted {
  opacity: .22;
}

.nav-lan {
  border: 0;
  background: none;
  color: #ffd700;
  text-align: left;
  padding: 8px 12px;
  border-radius: 4px;
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 21px;
  letter-spacing: .5px;
  cursor: pointer;
  text-shadow: 0 2px 10px #0008;
  white-space: nowrap;
  transition: .18s;
  width: fit-content; 
  display: block;
}

.nav-lan:hover {
  color: #ffd700;
  background: rgba(255, 215, 0, 0.08);
  transform: translateX(5px);
}

.nav-lan.active {
  color: #fff;
  background: rgba(255, 215, 0, 0.15);
  border-left: 4px solid #ffd700;
  font-size: 23px;
  padding-right: 18px;
}

.nav-lan.muted {
  opacity: .22;
}

@media(max-width: 1024px) {
  .burger-btn {
    width: 40px;
    height: 40px;
    font-size: 16px;
  }
  
  .brand-custom-logo {
    height: 34px !important;
  }

  .fc-logo {
    font-size: 28px !important;
  }

  .fc-logo span {
    font-size: 28px !important;
  }

  .sidebar {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(13, 19, 19, 0.96);
    backdrop-filter: blur(16px);
    padding: 70px 20px 20px 20px;
    flex-direction: column-reverse;
    justify-content: flex-end;
    align-items: center;
    z-index: 50;
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s ease;
  }

  .sidebar:not(.collapsed) {
    transform: translateY(0) !important;
    opacity: 1 !important;
    pointer-events: auto !important;
  }

  #mainNav, .rail {
    pointer-events: auto !important;
  }
  
  #mainNav {
    width: 100%;
    max-width: 400px;
    max-height: calc(100vh - 180px);
    align-items: stretch;
  }
  
  .rail {
    width: 100%;
    max-width: 400px;
    height: 48px;
    display: flex;
    flex-direction: row;
    justify-content: space-around;
    margin-top: 10px;
  }
  
  .rail-btn {
    width: 25%;
    height: 48px;
  }
  
  .rail-btn.active {
    box-shadow: inset 0 -3px var(--cyan);
  }

  .rail-close-mobile {
    display: flex !important;
    align-items: center;
    justify-content: center;
  }
}