.hamburger-btn {
  display: none;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  /*cursor: pointer;*/
  transition: all 0.3s ease;
  margin-right: 15px;
  z-index: 1001;
  position: relative;
}

.hamburger-btn:hover {
  background: var(--accent-color);
  transform: scale(1.05);
}

.hamburger-btn i {
  font-size: 1.5em;
  color: white;
}

.navbar-announcement {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  margin: auto 0 auto 0;
  color: white;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid var(--glass-border);
  font-size: 20px;
}

.sidebar {
  position: fixed;
  top: 0;
  right: -100%;
  width: 420px;
  height: 100%;
  background-color: #1a1a1a;
  backdrop-filter: blur(20px);
  border-left: 1px solid var(--glass-border);
  z-index: 2000;
  transition: right 0.3s ease;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

.sidebar.open {
  right: 0;
}

.sidebar-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1999;
  display: none;
}

.sidebar-overlay.active {
  display: block;
}

.sidebar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  border-bottom: 1px solid var(--glass-border);
  background-color: #1a1a1a;
  flex-shrink: 0;
}

.sidebar-header .logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.sidebar-header .logo img {
  width: 45px;
  height: 45px;
  border-radius: 12px;
}

.sidebar-header .logo span {
  font-size: 1em;
  font-family: 'Minecraft Title 2', sans-serif;
  color: white;
}

.sidebar-header .logo span .bold-pack {
  color: var(--ocean-color);
}

.close-sidebar {
  background: rgba(255,255,255,0.1);
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  /*cursor: pointer;*/
  color: white;
  font-size: 1.2em;
  transition: all 0.3s ease;
}

.close-sidebar:hover {
  background: var(--danger-color);
  transform: scale(1.1);
}

.sidebar-profile {
  padding: 20px;
  text-align: center;
  border-bottom: 1px solid var(--glass-border);
  background: rgba(255,255,255,0.03);
  flex-shrink: 0;
  gap: 7.5px;
}

.sidebar-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--accent-color);
  margin-bottom: 12px;
}

.sidebar-username {
  font-size: 1.2em;
  font-weight: bold;
  color: white;
  font-family: 'Minecraft Font', sans-serif;
  text-align: left;
  word-break: break-word;
  max-width: 100%;
  overflow-wrap: break-word;
}

.sidebar-user-bio {
  font-size: 0.8em;
  color: #aaa;
  margin-top: 8px;
  text-align: left;
  word-break: break-word;
  max-width: 100%;
  overflow-wrap: break-word;
}

.sidebar-nav {
  flex: 1 1 auto;
  padding: 15px 0 15px 10px;
  overflow-y: visible;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.sidebar-nav-item {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 12px 20px;
  color: white;
  transition: all 0.3s ease;
  font-family: 'Minecraft Font', sans-serif;
  border-left: 3px solid transparent;
}

.sidebar-nav-item:hover {
  background: rgba(255,255,255,0.1);
  width: 200px;
  height: 45px;
  border-radius: 14px;
  transform: translateY(3px);
}

.sidebar-nav-item i {
  width: 24px;
  color: var(--accent-color);
  font-size: 1.1em;
}

.sidebar-divider {
  height: 1px;
  background: var(--glass-border);
  margin: 8px 20px;
}

.sidebar-actions {
  padding: 15px 20px 25px 20px;
  border-top: 1px solid var(--glass-border);
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex-shrink: 0;
  background-color: #1a1a1a;
}

.sidebar-action-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 12px;
  border-radius: 30px;
  /*cursor: pointer;*/
  transition: all 0.3s ease;
  font-family: 'Minecraft Font', sans-serif;
  font-size: 0.95em;
  border: 1px solid var(--glass-border);
}

.sidebar-action-btn.login {
  background: var(--accent-color);
  color: white;
}

.sidebar-action-btn.register {
  background: var(--glass-bg);
  color: white;
}

.sidebar-action-btn.logout {
  background: var(--danger-color);
  color: white;
}

.sidebar-action-btn.upload {
  background: var(--success-color);
  color: white;
}

.sidebar-action-btn:hover {
  transform: translateY(-2px);
  filter: brightness(1.1);
}

.sidebar {
  scrollbar-width: thin;
  scrollbar-color: var(--accent-color) rgba(255,255,255,0.1);
}

.sidebar::-webkit-scrollbar {
  width: 5px;
}

.sidebar::-webkit-scrollbar-track {
  background: rgba(255,255,255,0.1);
  border-radius: 3px;
}

.sidebar::-webkit-scrollbar-thumb {
  background: var(--accent-color);
  border-radius: 3px;
}

.sidebar::-webkit-scrollbar-thumb:hover {
  background: var(--accent-hover);
}

@media (min-width: 1001px) and (max-width: 1762px) {
  body.desktop-layout {
    display: flex;
    flex-direction: row;
    padding: 0 !important;
    margin: 0;
    min-height: 100vh;
    overflow: hidden;
    height: 100vh;
  }
  
  body.desktop-layout .sidebar {
    position: relative !important;
    right: auto !important;
    top: auto !important;
    width: 420px;
    height: 100vh;
    flex-shrink: 0;
    z-index: auto;
    transition: none;
    border-left: 1px solid var(--glass-border);
    border-right: none;
    box-shadow: none;
    overflow-y: auto;
    overflow-x: hidden;
  }
  
  body.desktop-layout .main-container {
    flex: 1;
    min-width: 0;
    padding: 20px;
    margin: 0;
    overflow-x: hidden;
    overflow-y: auto;
    height: 100vh;
  }
  
  body.desktop-layout .sidebar-overlay {
    display: none !important;
  }
  
  body.desktop-layout .close-sidebar {
    display: none !important;
  }
  
  body.desktop-layout .hamburger-btn {
    display: none !important;
  }
  
  body.desktop-layout nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 420px;
    width: auto;
    margin-bottom: 20px;
    background: rgba(0,0,0,0);
    border-bottom: 0.2px solid transparent;
    transition: border-color 0.3s ease-in-out;
    transition: background 0.3s ease-in-out;
  }
  
  body.desktop-layout nav.scrolled {
    border-bottom-color: var(--button-hover) !important;
    background: rgba(0,0,0,0.4) !important;
  }
}

@media (max-width: 992px) {
  .hamburger-btn {
    display: flex;
  }
  
  nav .header-actions {
    display: none !important;
  }
  
  nav {
    justify-content: flex-end;
  }
  
  .minepacknode {
    position: relative;
    left: 0;
    margin-right: auto;
  }
}

@media (max-width: 768px) {
  .sidebar {
    width: 280px;
  }
  
  .sidebar-nav-item {
    padding: 10px 16px;
    font-size: 0.9em;
  }
  
  .sidebar-action-btn {
    padding: 10px;
    font-size: 0.9em;
  }
  
  .sidebar-username {
    font-size: 1.1em;
  }
  
  .sidebar-user-bio {
    font-size: 0.75em;
  }
}